development efforts on the Solaris side.

Poul-Henning Kamp phk at phk.freebsd.dk
Thu Jan 10 23:07:49 CET 2008


In message <03B017F1-86E3-45AD-9387-10CD3B80AC32 at omniti.com>, Theo Schlossnagle
 writes:

>> mgt_vcc.c:
>> 	The suffix shouldn't matter to dlopen(), please explain ?
>> 	White-space and {} spam.
>> 	Adding the c-compiler command to the error message is bound
>> 	to make it overflow the linewidth.
>
>It isn't dlopen, it is the compiler linker chain that fails on  
>Solaris.  While it is arguable that it is a SunStudio bug, I think the  
>limitation is extremely unnecessary and annoying -- but alas.  The  
>work around does not break gcc.

Then just specify a compiler parameter as:
	"cc -bla -bla -o %o.so %s && mv %o.so %o"

>> -/* Note: intentionally not IOV_MAX */
>> +#ifdef IOV_MAX
>> +#define MAX_IOVS	IOV_MAX
>> +#else
>> #define MAX_IOVS	(HTTP_HDR_MAX * 2)
>> +#endif
>>
>> 	Which bit of "intentionally" didn't you understand ?
>> 	Have you examined the value of IOV_MAX, looked at where
>> 	this is used and measured the impact ?
>
>I understood intentionally.  I also understood that it doesn't work on  
>Solaris.  On Solaris, IOV_MAX is the maximum number of elements  that  
>can be passed to writev(2), using a larger number will fail.

I will fix this to use IOV_MAX if it is less than the desired size.

>> cache_acceptor.c
>> 	Under no circumstances should #ifdef HAVE_PORT_CREATE be
>> 	necessary here.  If a new method is necessary for the
>> 	acceptors, so be it.
>
>Completely agreed.  I noted that it was a hack in a previous email.   
>I'd like that add the ping stuff as a function into each acceptor so  
>they can have their own approach to waking the acceptor thread up.   
>Solaris' portfs is much more like kqueue than epoll and support more  
>than just filedescriptors.  It allows user-space eventing, so it is  
>really easy to have one thread just say "dude, wake up" to another  
>waiting in port_get(n).  People tend to have strong preferences to  
>adding functions to structures in C, so I was pretty confident that I  
>should propose the design before implementing it, as it would likely  
>be redone.

I'm not sure I see what the point is here ?

I'll pull in the KEY_RESIZE #ifdef also.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



More information about the varnish-dev mailing list