Change Summary:
I updated using epoll.h as a basis. Also, I updated to use most recent first for the copyright.
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 2 (+129 -276) |
-
-
-
usr/src/uts/common/sys/null.h (Diff revision 2) If this is copyright by someone else, where did it come from originally? Presumably you need to honor their original license.
-
Change Summary:
Cstyle doesn't like null.h without the SYS_NULL_H define so I left it.
I did remove Mr Molenaar's copyright as nothing at all from his file is used here.
Added a <tab> after the #define for the 'long' NULL macroI also reverted getoptstr.h and put the include of null.h directly in getoptstr.c as there seems
to be only two clients of getopstr.h, one doesn't use NULL at all, the other picks it up via sys/params.h
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 3 (+128 -273) |
-
-
-
usr/src/head/fmtmsg.h (Diff revision 3) Any reason these are open-coded instead of using ((char *)NULL)?
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 4 (+129 -274) |
Change Summary:
As discussed offline with Jeff, we deem safer to keep parens on 'long' definition in case of problematic expressions
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 5 (+129 -274) |
-
-
usr/src/cmd/mdb/common/mdb/mdb_modapi.h (Diff revision 5) We still are trying to make sure that NULL has its standard definition by means of including <sys/null.h>. Probably worth updating the comment to add something like, 'We make sure that module writers get NULL by including <sys/null.h>'.
-
usr/src/cmd/sh/pwd.c (Diff revision 5) If you're fixing the cstyle here, then this brace should open on the line with the while statement.
-
usr/src/cmd/sh/pwd.c (Diff revision 5) Please use the null character '\0' for terminating here and at +90. Especially given that the file uses '\0' later on at +190/191.
-
-
-
-
usr/src/common/util/getoptstr.c (Diff revision 5) With the current NULL definition, don't we now regress this file and change the type that it sees for null?
-
usr/src/head/rpcsvc/dbm.h (Diff revision 5) What impact doest his have on consumers who previously saw this as a pointer? Does this wsdiff cleanly?
-
usr/src/ucbhead/sys/param.h (Diff revision 5) If someone is using the ucb headers where does the definition for NULL now come from?
Change Summary:
I believe this update covers most of Robert's remarks, and previously already Jeff's.
I didn't close issues as fixed where perhaps the creator had more questions.
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 6 (+142 -289) |
Change Summary:
This wsdiff is just to compare
< #if defined(_LP64) || defined(_I32LPx)
---
> #if defined(_LP64)using '#define NULL 0L'
In theory, on x86 at least, the results should be the same
as -m32 should generate _ILP32 and -m64 should generate _LP64
providing '0L' for all practical cases (in KERNEL, that is).Non-KERNEL code shouldn't see _I32LPx, meaning i386 should see '#define NULL 0'
In absence of egregious KERNEL bugs in the gate with respect to this methodology, the
explication of the differences should theoretically be limited to different, but equivalent, code
generation.An example of a bug would be, naturally, using NULL for other than a null pointer constant
in a context where the size is not the same and implicit conversion rules don't do the job
(aggravated in functions without prototypes, variadics and diverse static data storage déclarations).But since we know there are turds of this kind, it seems perhaps imprudent to use the _I32LPx
guard until these are duly cleaned up and the real 5218 with '#define NULL ((void *)0)' is committed
resulting in far less manure, thanks to the compiler doing its part.Again, the purpose of this patchset is to permit the clean up phase to more easily and quickly progress.
Added Files: |
---|
Change Summary:
I found that VERSION in illums.sh causes some hassles with wsdiff, so I set it the same and
reran the builds first master, then this latest.richard@omnis:/home/richard/src/illumos-gate$ wsdiff -dvVtr /tmp/wsdiffx.log proto/root_i386-nd.prev/ proto/root_i386-nd ## Getting the list of files in the base area ## Found 28089 files ## Getting the list of files in the patch area ## Found 28090 files ## Determining the list of regular files in the base area ## Found 21869 files ## Determining the list of regular files in the patch area ## Found 21870 files ## Searching for deleted files by comparing the lists ## Found 0 deleted files ## Eliminating deleted files from the list of objects ## List for comparison reduced to 21869 files ## Getting the list of newly added files ## Found 1 new files New objects found: usr/include/sys/null.h Changed objects: ## Setting signal handler ## Spawning 14 threads ## Waiting for the threads to finish usr/lib/smbsrv/amd64/libfksmbsrv.so.1 usr/lib/smbsrv/libfksmbsrv.so.1 usr/lib/amd64/libzpool.so.1 usr/lib/nfs/mountd usr/lib/libc/libc_hwcap2.so.1 usr/lib/libc/libc_hwcap1.so.1 usr/lib/libc/libc_hwcap3.so.1 usr/lib/libzpool.so.1 usr/sbin/isns usr/include/sys/sysevent.h usr/include/sys/param.h usr/include/sys/mdb_modapi.h usr/include/rpc/types.h usr/include/rpcsvc/dbm.h usr/include/iso/string_iso.h usr/include/iso/wchar_iso.h usr/include/iso/stdlib_iso.h usr/include/iso/time_iso.h usr/include/iso/locale_iso.h usr/include/iso/stdio_iso.h usr/include/iso/stddef_iso.h usr/include/unistd.h usr/include/mon.h usr/include/fmtmsg.h etc/motd lib/amd64/libc.so.1 lib/amd64/libnsl.so.1 lib/libnsl.so.1 lib/libc.so.1 ## Performing cleanup (0)so ignoring .debug_info and .SUNW_dof only lib/libnsl.so.1 and lib/amd64/libnsl.so.1 had any pertinent differences.
so I dis'd them and see for lib/nsl.so.1:richard@omnis:/home/richard/src/illumos-gate$ diff -u /tmp/libnsl.dis.0 /tmp/libnsl.dis.1 --- /tmp/libnsl.dis.0 lun. janv. 18 18:41:58 2016 +++ /tmp/libnsl.dis.1 lun. janv. 18 18:42:04 2016 @@ -1,4 +1,4 @@ -disassembly for proto/root_i386-nd.prev/lib/libnsl.so.1 +disassembly for proto/root_i386-nd/lib/libnsl.so.1 section .plt @@ -86805,9 +86805,9 @@ nextkey+0x20: 89 45 bc movl %eax,-0x44(%ebp) nextkey+0x23: 89 04 24 movl %eax,(%esp) nextkey+0x26: e8 d0 fd ff ff call -0x230 <dbm_access> - nextkey+0x2b: c7 45 d0 01 00 00 movl $0x1,-0x30(%ebp) + nextkey+0x2b: c7 45 d8 00 00 00 movl $0x0,-0x28(%ebp) 00 - nextkey+0x32: c7 45 d8 00 00 00 movl $0x0,-0x28(%ebp) + nextkey+0x32: c7 45 d0 01 00 00 movl $0x1,-0x30(%ebp) 00 nextkey+0x39: 83 c4 10 addl $0x10,%esp nextkey+0x3c: 8d 45 e0 leal -0x20(%ebp),%eaxa simple line swap.
amd64/libnsl.so.1 seems to have quite a bit more addresses juggling around.
Added Files: |
---|
Change Summary:
This is the latest patchset avoiding parens around '0L' and dropping, for the time being, the '_I32LPx' guard
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 7 (+142 -289) |
-
Otherwise I'm fairly happy with this at this point. Thanks for going through and getting the wsdiff results together.
-
usr/src/uts/common/sys/null.h (Diff revision 7) Please remove the commented out _ILP32X before this goes back.