ICU-2403 Fix for iSeries, which has 16 byte (128-bit) pointers.
X-SVN-Rev: 13946
This commit is contained in:
parent
f3f79d3e26
commit
6146c58a70
@ -189,12 +189,17 @@ static void TestTraceAPI() {
|
||||
test_format("a 64 bit val %l", 50, 0, "a 64 bit val 123456780abcdef0"
|
||||
, __LINE__, INT64_C(0x123456780abcdef0));
|
||||
|
||||
if (sizeof(ptr) == 4) {
|
||||
if (sizeof(void *) == 4) {
|
||||
ptr = (void *)0xdeadbeef;
|
||||
test_format("a 32 bit ptr %p", 50, 0, "a 32 bit ptr deadbeef", __LINE__, ptr);
|
||||
} else if (sizeof(void *) == 8) {
|
||||
ptr = (void *) INT64_C(0x1000200030004000);
|
||||
test_format("a 64 bit ptr %p", 50, 0, "a 64 bit ptr 1000200030004000", __LINE__, ptr);
|
||||
} else if (sizeof(void *) == 16) {
|
||||
/* iSeries */
|
||||
int32_t massiveBigEndianPtr[] = { 0x10002000, 0x30004000, 0x50006000, 0x70008000 };
|
||||
ptr = *((void **)massiveBigEndianPtr);
|
||||
test_format("a 128 bit ptr %p", 50, 0, "a 128 bit ptr 10002000300040005000600070008000", __LINE__, ptr);
|
||||
} else {
|
||||
TEST_ASSERT(FALSE);
|
||||
/* TODO: others? */
|
||||
|
Loading…
Reference in New Issue
Block a user