Re: LLVM miscompiles numeric.c access to short numeric var headers
В списке pgsql-hackers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: LLVM miscompiles numeric.c access to short numeric var headers |
| Дата | |
| Msg-id | 28319.1447346595@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: LLVM miscompiles numeric.c access to short numeric var headers (Greg Stark <stark@mit.edu>) |
| Ответы |
Re: LLVM miscompiles numeric.c access to short numeric var headers
|
| Список | pgsql-hackers |
Greg Stark <stark@mit.edu> writes:
> On Thu, Nov 12, 2015 at 3:51 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> I think we could fix the immediate issue by redeclaring numeric
>> headers as arrays of (u)int16 rather than structs. I'm not
>> very excited about the packed-header case.
> That would require giving up the pretense that the code supports base
> 10 and base 100 I suppose.
No, not really. If we redefine NumericVar as a uint16 array,
then we'd have n_header or n_sign_dscale as array[0],
n_weight as (int16) array[1], and n_data as (NumericDigit *) &array[1]
or (NumericDigit *) &array[2] depending. Doesn't matter which
way NumericDigit is declared.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера