summaryrefslogtreecommitdiffstats
path: root/src/include/compiler.h
diff options
context:
space:
mode:
authorHolger Lubitz2007-08-02 01:01:01 +0200
committerHolger Lubitz2007-08-02 01:01:01 +0200
commite3d10ac6734833e94d329c517c868223d530a955 (patch)
tree7d431f3b058d78fcbf7b77dc11fc22ad25531340 /src/include/compiler.h
parentmemscan does not alter the mem pointer - make it const (diff)
downloadipxe-e3d10ac6734833e94d329c517c868223d530a955.tar.gz
ipxe-e3d10ac6734833e94d329c517c868223d530a955.tar.xz
ipxe-e3d10ac6734833e94d329c517c868223d530a955.zip
define __nonnull
Diffstat (limited to 'src/include/compiler.h')
-rw-r--r--src/include/compiler.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/include/compiler.h b/src/include/compiler.h
index e79f9fb2..32416a56 100644
--- a/src/include/compiler.h
+++ b/src/include/compiler.h
@@ -292,6 +292,13 @@ extern void dbg_hex_dump_da ( unsigned long dispaddr,
#define __const __attribute__ (( const ))
/**
+ * Declare a function's pointer parameters as non-null - i.e. force
+ * compiler to check pointers at compile time and enable possible
+ * optimizations based on that fact
+ */
+#define __nonnull __attribute__ (( nonnull ))
+
+/**
* Declare a function as used.
*
* Necessary only if the function is called only from assembler code.