utility.hh (9764:7e744dcb1904) | utility.hh (9765:da0e0df0ba97) |
---|---|
1/* 2 * Copyright (c) 2007 The Hewlett-Packard Development Company 3 * All rights reserved. 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 127 unchanged lines hidden (view full) --- 136 void setRFlags(ThreadContext *tc, uint64_t val); 137 138 /** 139 * Extract the bit string representing a double value. 140 */ 141 inline uint64_t getDoubleBits(double val) { 142 return *(uint64_t *)(&val); 143 } | 1/* 2 * Copyright (c) 2007 The Hewlett-Packard Development Company 3 * All rights reserved. 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 127 unchanged lines hidden (view full) --- 136 void setRFlags(ThreadContext *tc, uint64_t val); 137 138 /** 139 * Extract the bit string representing a double value. 140 */ 141 inline uint64_t getDoubleBits(double val) { 142 return *(uint64_t *)(&val); 143 } |
144 145 /** 146 * Generate and updated x87 tag register after a push/pop 147 * operation. 148 * 149 * @note There is currently no support for setting other tags than 150 * valid and invalid. A real x87 will set the tag value to zero or 151 * special for some special floating point values. 152 * 153 * @param ftw Current value of the FTW register. 154 * @param top Current x87 TOP value. 155 * @param spm Stack displacement. 156 * @return New value of the FTW register. 157 */ 158 uint16_t genX87Tags(uint16_t ftw, uint8_t top, int8_t spm); |
|
144} 145 146#endif // __ARCH_X86_UTILITY_HH__ | 159} 160 161#endif // __ARCH_X86_UTILITY_HH__ |