自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(5)
  • 收藏
  • 关注

原创 如何使用epoll? 一个C语言的简单例子

* How to use epoll? A complete example in C 译文 通常的网络服务器实现, 是对每一个连接使用一个单独的线程或进程。对高性能应用而言,由于需要同时处理非常多的客户请求, 所以这种方式并不能工作得很好,因为诸如资源使用和上下文切换所需的时间影响了在一时间内对多个客户端进行处理。另一个可选的途径是在一个单独的线程里采用非阻塞的I/O, 这样当可以从一个s...

2012-04-12 12:07:30 277

IPC 互斥锁和条件变量

在多线程或多进程间共享数据时,为了保证共享数据的正确性,同步是必不可少的。其中,互斥锁与条件变量是同步的重要组成部分, 互斥锁用来上锁, 条件变量用来等待。 1.1 互斥锁 互斥是指相互排斥(mutual exclusion)。互斥锁用于保护临界区(critical region), 以保证任何时刻只有一个线程(进程)在执行其中的代码,假设互斥锁由多个线程(...

2011-09-19 20:53:45 89

Reading notes for the 20th chapter 'Broadcasting' of unp.

[size=medium]We know that information transmission means through the Ethernet consist of unicasting, multicasting, anycasting and broadcasting. The following table show differen forms of addressing. ...

2011-08-28 21:51:33 80

Why do the SICP Exercise?

[size=medium]I decide to do the exercises of the book of SICP, and put them on javaeye. Before this decision, I saw a person who had spent one whole year on reading the SICP, and publised his think...

2011-08-28 18:19:33 83

SICP Exercise 1.1 to Exercise 1.6

[size=medium] Exercise 1.1 This exercise is very easy, just evaluate some expressions.[/size] [code="scheme"] 1 ]=> 10 ;Value: 10 1 ]=> (+ 5 3 4) ;Value: 12 1 ]=> (- 9 1) ;Value: 8 ...

2011-08-28 18:18:41 233

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除