Changeset 58666 in vbox for trunk/src/VBox/ValidationKit
- Timestamp:
- Nov 12, 2015 12:04:31 AM (9 years ago)
- Location:
- trunk/src/VBox/ValidationKit/bootsectors/bs3kit
- Files:
-
- 5 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/bootsectors/bs3kit/Makefile.kmk
r58663 r58666 91 91 -o $(obj)\ 92 92 $(abspath $(source)) 93 ls -la $(obj) 94 -$(VBoxBs3ObjConverter_1_TARGET) -vv "$(obj)" 93 $(QUIET)$(VBoxBs3ObjConverter_1_TARGET) "$(obj)" 95 94 $(QUIET)$(APPEND) -n "$(dep)" "" "$(source):" "" 96 95 endef … … 113 112 -o $(obj)\ 114 113 $(abspath $(source)) 115 $(QUIET)$(VBoxBs3ObjConverter_1_TARGET) -v"$(obj)"114 $(QUIET)$(VBoxBs3ObjConverter_1_TARGET) "$(obj)" 116 115 $(QUIET)$(APPEND) -n "$(dep)" "" "$(source):" "" 117 116 endef … … 137 136 define TOOL_Bs3Vcc64_COMPILE_C_CMDS 138 137 $(TOOL_$(VBOX_VCC_TOOL_STEM)AMD64_COMPILE_C_CMDS) 139 -$(VBoxBs3ObjConverter_1_TARGET) -vv"$(obj)"138 -$(VBoxBs3ObjConverter_1_TARGET) "$(obj)" 140 139 endef 141 140 … … 154 153 define TOOL_Bs3Vcc64_COMPILE_CXX_CMDS 155 154 $(TOOL_$(VBOX_VCC_TOOL_STEM)AMD64_COMPILE_CXX_CMDS) 156 $(QUIET)$(VBoxBs3ObjConverter_1_TARGET) -v"$(obj)"155 $(QUIET)$(VBoxBs3ObjConverter_1_TARGET) "$(obj)" 157 156 endef 158 157 … … 310 309 bs3-cmn-PrintStrColonSpaces.asm \ 311 310 bs3-cmn-PrintStrSpacesColonSpace.c \ 311 bs3-cmn-StrLen.c \ 312 bs3-cmn-StrNLen.c \ 313 bs3-cmn-StrCpy.c \ 314 bs3-cmn-MemCpy.c \ 315 bs3-cmn-MemPCpy.c \ 312 316 313 317 # The BS3Kit library. -
trunk/src/VBox/ValidationKit/bootsectors/bs3kit/bs3kit-template-header.h
r58628 r58666 25 25 */ 26 26 27 #include "bs3kit. mac"27 #include "bs3kit.h" 28 28 29 29 /** @defgroup grp_bs3kit_tmpl BS3Kit Multi-Mode Code Templates … … 116 116 #else /* !DOXYGEN_RUNNING */ 117 117 118 #undef BS3_CMN_NM 119 118 120 #ifdef TMPL_RM 119 121 # ifdef TMPL_PE16 -
trunk/src/VBox/ValidationKit/bootsectors/bs3kit/bs3kit.h
r58628 r58666 89 89 #define BS3_CMN_NM(a_Name) RT_CONCAT3(a_Name,_c,ARCH_BITS) 90 90 91 /** 92 * Template for createing a pointer union type. 93 * @param a_BaseName The base type name. 94 * @param a_Modifier The type modifier. 95 */ 96 #define BS3_PTR_UNION_TEMPLATE(a_BaseName, a_Modifiers) \ 97 typedef union a_BaseName \ 98 { \ 99 /** Pointer into the void. */ \ 100 a_Modifiers void BS3_FAR *pv; \ 101 /** As a signed integer. */ \ 102 intptr_t i; \ 103 /** As an unsigned integer. */ \ 104 uintptr_t u; \ 105 /** Pointer to char value. */ \ 106 a_Modifiers char BS3_FAR *pch; \ 107 /** Pointer to char value. */ \ 108 a_Modifiers unsigned char BS3_FAR *puch; \ 109 /** Pointer to a int value. */ \ 110 a_Modifiers int BS3_FAR *pi; \ 111 /** Pointer to a unsigned int value. */ \ 112 a_Modifiers unsigned int BS3_FAR *pu; \ 113 /** Pointer to a long value. */ \ 114 a_Modifiers long BS3_FAR *pl; \ 115 /** Pointer to a long value. */ \ 116 a_Modifiers unsigned long BS3_FAR *pul; \ 117 /** Pointer to a memory size value. */ \ 118 a_Modifiers size_t BS3_FAR *pcb; \ 119 /** Pointer to a byte value. */ \ 120 a_Modifiers uint8_t BS3_FAR *pb; \ 121 /** Pointer to a 8-bit unsigned value. */ \ 122 a_Modifiers uint8_t BS3_FAR *pu8; \ 123 /** Pointer to a 16-bit unsigned value. */ \ 124 a_Modifiers uint16_t BS3_FAR *pu16; \ 125 /** Pointer to a 32-bit unsigned value. */ \ 126 a_Modifiers uint32_t BS3_FAR *pu32; \ 127 /** Pointer to a 64-bit unsigned value. */ \ 128 a_Modifiers uint64_t BS3_FAR *pu64; \ 129 /** Pointer to a UTF-16 character. */ \ 130 a_Modifiers RTUTF16 BS3_FAR *pwc; \ 131 /** Pointer to a UUID character. */ \ 132 a_Modifiers RTUUID BS3_FAR *pUuid; \ 133 } a_BaseName; \ 134 /** Pointer to a pointer union. */ \ 135 typedef a_BaseName *RT_CONCAT(P,a_BaseName) 136 BS3_PTR_UNION_TEMPLATE(BS3PTRUNION, RT_NOTHING); 137 BS3_PTR_UNION_TEMPLATE(BS3CPTRUNION, const); 138 BS3_PTR_UNION_TEMPLATE(BS3VPTRUNION, volatile); 139 BS3_PTR_UNION_TEMPLATE(BS3CVPTRUNION, const volatile); 91 140 92 141 … … 106 155 */ 107 156 BS3_DECL(void) Bs3Panic_c16(void); 108 BS3_DECL(void) Bs3Panic_c32(void); 109 BS3_DECL(void) Bs3Panic_c64(void); 110 #define Bs3Panic BS3_CMN_NM(Bs3Panic) 157 BS3_DECL(void) Bs3Panic_c32(void); /**< @copydoc Bs3Panic_c16 */ 158 BS3_DECL(void) Bs3Panic_c64(void); /**< @copydoc Bs3Panic_c16 */ 159 #define Bs3Panic BS3_CMN_NM(Bs3Panic) /**< Selects #Bs3Panic_c16, #Bs3Panic_c32 or #Bs3Panic_c64. */ 111 160 112 161 /** … … 117 166 */ 118 167 BS3_DECL(void) Bs3Shutdown_c16(void); 119 BS3_DECL(void) Bs3Shutdown_c32(void); 120 BS3_DECL(void) Bs3Shutdown_c64(void); 121 #define Bs3Shutdown BS3_CMN_NM(Bs3Shutdown) 168 BS3_DECL(void) Bs3Shutdown_c32(void); /**< @copydoc Bs3Shutdown_c16 */ 169 BS3_DECL(void) Bs3Shutdown_c64(void); /**< @copydoc Bs3Shutdown_c16 */ 170 #define Bs3Shutdown BS3_CMN_NM(Bs3Shutdown) /**< Selects #Bs3Shutdown_c16, #Bs3Shutdown_c32 or #Bs3Shutdown_c64. */ 122 171 123 172 /** … … 129 178 BS3_DECL(void) Bs3PrintU32_c32(uint32_t uValue); /**< @copydoc Bs3PrintU32_c16 */ 130 179 BS3_DECL(void) Bs3PrintU32_c64(uint32_t uValue); /**< @copydoc Bs3PrintU32_c16 */ 131 #define Bs3PrintU32 BS3_CMN_NM(Bs3PrintU32) /**< Selects #Bs3PrintU32_c16, #Bs3PrintU32_c32 or #Bs3PrintU32_c64. */ 180 #define Bs3PrintU32 BS3_CMN_NM(Bs3PrintU32) /**< Selects #Bs3PrintU32_c16, #Bs3PrintU32_c32 or #Bs3PrintU32_c64. */ 181 182 /** 183 * Finds the length of a zero terminated string. 184 * 185 * @returns String length in chars/bytes. 186 * @param pszString The string to examine. 187 */ 188 BS3_DECL(size_t) Bs3StrLen_c16(const char BS3_FAR *pszString); 189 BS3_DECL(size_t) Bs3StrLen_c32(const char BS3_FAR *pszString); /** @copydoc Bs3StrLen_c16 */ 190 BS3_DECL(size_t) Bs3StrLen_c64(const char BS3_FAR *pszString); /** @copydoc Bs3StrLen_c16 */ 191 #define Bs3StrLen BS3_CMN_NM(Bs3StrLen) /**< Selects #Bs3StrLen_c16, #Bs3StrLen_c32 or #Bs3StrLen_c64. */ 192 193 /** 194 * Finds the length of a zero terminated string, but with a max length. 195 * 196 * @returns String length in chars/bytes, or @a cchMax if no zero-terminator 197 * was found before we reached the limit. 198 * @param pszString The string to examine. 199 * @param cchMax The max length to examine. 200 */ 201 BS3_DECL(size_t) Bs3StrNLen_c16(const char BS3_FAR *pszString, size_t cchMax); 202 BS3_DECL(size_t) Bs3StrNLen_c32(const char BS3_FAR *pszString, size_t cchMax); /** @copydoc Bs3StrNLen_c16 */ 203 BS3_DECL(size_t) Bs3StrNLen_c64(const char BS3_FAR *pszString, size_t cchMax); /** @copydoc Bs3StrNLen_c16 */ 204 #define Bs3StrNLen BS3_CMN_NM(Bs3StrNLen) /**< Selects #Bs3StrNLen_c16, #Bs3StrNLen_c32 or #Bs3StrNLen_c64. */ 205 206 /** 207 * CRT style unsafe strcpy. 208 * 209 * @returns pszDst. 210 * @param pszDst The destination buffer. Must be large enough to 211 * hold the source string. 212 * @param pszSrc The source string. 213 */ 214 BS3_DECL(char BS3_FAR *) Bs3StrCpy_c16(char BS3_FAR *pszDst, const char BS3_FAR *pszSrc); 215 BS3_DECL(char BS3_FAR *) Bs3StrCpy_c32(char BS3_FAR *pszDst, const char BS3_FAR *pszSrc); /** @copydoc Bs3StrCpy_c16 */ 216 BS3_DECL(char BS3_FAR *) Bs3StrCpy_c64(char BS3_FAR *pszDst, const char BS3_FAR *pszSrc); /** @copydoc Bs3StrCpy_c16 */ 217 #define Bs3StrCpy BS3_CMN_NM(Bs3StrCpy) /**< Selects #Bs3StrCpy_c16, #Bs3StrCpy_c32 or #Bs3StrCpy_c64. */ 218 219 /** 220 * CRT style memcpy 221 * 222 * @returns pvDst 223 * @param pvDst The destination buffer. 224 * @param pvSrc The source buffer. 225 * @param cbCopy The number of bytes to copy. 226 */ 227 BS3_DECL(void BS3_FAR *) Bs3MemCpy_c16(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); 228 BS3_DECL(void BS3_FAR *) Bs3MemCpy_c32(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); /** @copydoc Bs3MemCpy_c16 */ 229 BS3_DECL(void BS3_FAR *) Bs3MemCpy_c64(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); /** @copydoc Bs3MemCpy_c16 */ 230 #define Bs3MemCpy BS3_CMN_NM(Bs3MemCpy) /**< Selects #Bs3MemCpy_c16, #Bs3MemCpy_c32 or #Bs3MemCpy_c64. */ 231 232 /** 233 * GNU (?) style mempcpy 234 * 235 * @returns pvDst + cbCopy 236 * @param pvDst The destination buffer. 237 * @param pvSrc The source buffer. 238 * @param cbCopy The number of bytes to copy. 239 */ 240 BS3_DECL(void BS3_FAR *) Bs3MemPCpy_c16(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); 241 BS3_DECL(void BS3_FAR *) Bs3MemPCpy_c32(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); /** @copydoc Bs3MemPCpy_c16 */ 242 BS3_DECL(void BS3_FAR *) Bs3MemPCpy_c64(void BS3_FAR *pvDst, const void BS3_FAR *pvSrc, size_t cbToCopy); /** @copydoc Bs3MemPCpy_c16 */ 243 #define Bs3MemPCpy BS3_CMN_NM(Bs3MemPCpy) /**< Selects #Bs3MemPCpy_c16, #Bs3MemPCpy_c32 or #Bs3MemPCpy_c64. */ 132 244 133 245 /** @} */
Note:
See TracChangeset
for help on using the changeset viewer.