From bbac9ab2406efa647d0b773078f76712ae376164 Mon Sep 17 00:00:00 2001 From: Bill Schmidt Date: Mon, 27 Aug 2018 14:10:11 -0500 Subject: [PATCH] Define #lo34, #hi30, #ha30. Fix pastos in relocs 123-126. Fix all prefix31 relocs to use prefix30 and >> 4. Fix all prefix25 relocs to use prefix 24 and >> 4. Add relocs 144-148. Signed-off-by: Bill Schmidt --- specification/ch_3.xml | 169 ++++++++++++++++++++++++++++++++++------- 1 file changed, 141 insertions(+), 28 deletions(-) diff --git a/specification/ch_3.xml b/specification/ch_3.xml index 7201453..70f4dab 100644 --- a/specification/ch_3.xml +++ b/specification/ch_3.xml @@ -2901,6 +2901,49 @@ my_func: #highesta(x) = (x + 0x8000) >> 48 + + + #lo34(value) + + + + Denotes the least-significant 34 bits of the indicated + 64-bit value. That is: + + + #lo34(x) = x & 0x3ffffffff + + + + + + #hi30(value) + + + + Denotes bits 34–63 of the indicated 64-bit value. + That is: + + + #hi30(x) = x >> 34 + + + + + + #ha30(value) + + + + Denotes the high adjusted value: bits 34–63 of the + indicated 64-bit value, compensating for #lo34() being + treated as a signed number. That is: + + + #ha30(x) = (x + 0x200000000) >> 34 + + + TP @@ -4771,7 +4814,7 @@ my_func: half16 - #lo(L – .TOC.) + #lo(L – P) @@ -4785,7 +4828,7 @@ my_func: half16* - #hi(L – .TOC.) + #hi(L – P) @@ -4799,7 +4842,7 @@ my_func: half16* - #ha(L – .TOC.) + #ha(L – P) @@ -4813,7 +4856,7 @@ my_func: half16ds - #lo(L – .TOC.) >> 2 + #lo(L – P) >> 2 @@ -4846,30 +4889,30 @@ my_func: - R_PPC64_PCREL31 + R_PPC64_PCREL30 129 - prefix31* + prefix30* - (S + A – P) >> 3 + (S + A – P) >> 4 - R_PPC64_PCREL25 + R_PPC64_PCREL24 130 - prefix25* + prefix24* - (S + A – P) >> 3 + (S + A – P) >> 4 @@ -4902,30 +4945,30 @@ my_func: - R_PPC64_GOT_PCREL31 + R_PPC64_GOT_PCREL30 133 - prefix31* + prefix30* - (G – P) >> 3 + (G – P) >> 4 - R_PPC64_GOT_PCREL25 + R_PPC64_GOT_PCREL24 134 - prefix25* + prefix24* - (G – P) >> 3 + (G – P) >> 4 @@ -4972,30 +5015,30 @@ my_func: - R_PPC64_PLT_PCREL31 + R_PPC64_PLT_PCREL30 138 - prefix31* + prefix30* - (L – P) >> 3 + (L – P) >> 4 - R_PPC64_PLT_PCREL25 + R_PPC64_PLT_PCREL24 139 - prefix25* + prefix24* - (L – P) >> 3 + (L – P) >> 4 @@ -5028,30 +5071,100 @@ my_func: - R_PPC64_PLT_PCREL31_NOTOC + R_PPC64_PLT_PCREL30_NOTOC 142 - prefix31* + prefix30* - (L – P) >> 3 + (L – P) >> 4 - R_PPC64_PLT_PCREL25_NOTOC + R_PPC64_PLT_PCREL24_NOTOC 143 - prefix25* + prefix24* + + + (L – P) >> 4 + + + + + R_PPC64_ADDR64_LO34 + + + 144 + + + prefix34* + + + #lo34(S + A) + + + + + R_PPC64_ADDR64_LO32 + + + 145 + + + prefix32* + + + #lo34(S + A) >> 2 + + + + + R_PPC64_ADDR64_LO30 + + + 146 + + + prefix30* + + + #lo34(S + A) >> 4 + + + + + R_PPC64_ADDR64_HI30 + + + 147 + + + prefix34* + + + #hi30(S + A) + + + + + R_PPC64_ADDR64_HA30 + + + 148 + + + prefix34* - (L – P) >> 3 + #ha30(S + A)