[ 
https://issues.apache.org/jira/browse/ARROW-5007?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Wes McKinney reassigned ARROW-5007:
-----------------------------------

    Assignee: Francois Saint-Jacques

> [C++] Move DCHECK out of sse-utils 
> -----------------------------------
>
>                 Key: ARROW-5007
>                 URL: https://issues.apache.org/jira/browse/ARROW-5007
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: C++
>            Reporter: Francois Saint-Jacques
>            Assignee: Francois Saint-Jacques
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 0.14.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Some users tried to compile arrow on ppc64, but they face the following error
> {code:bash}
> In file included from /root/repos/arrow/cpp/src/arrow/json/chunker.h:26:0,
>                  from /root/repos/arrow/cpp/src/arrow/json/chunker.cc:18:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘__m128i 
> arrow::SSE4_cmpestrm(__m128i, int, __m128i, int)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:125:3: error: there are no 
> arguments to ‘DCHECK’ that depend on a template parameter, so a declaration 
> of ‘DCHECK’ must be available [-fpermissive]
>    DCHECK(false) << "CPU doesn't support SSE 4.2";
>    ^~~~~~
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:125:3: note: (if you use 
> ‘-fpermissive’, G++ will accept your code, but allowing the use of an 
> undeclared name is deprecated)
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘int 
> arrow::SSE4_cmpestri(__m128i, int, __m128i, int)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:131:3: error: there are no 
> arguments to ‘DCHECK’ that depend on a template parameter, so a declaration 
> of ‘DCHECK’ must be available [-fpermissive]
>    DCHECK(false) << "CPU doesn't support SSE 4.2";
>    ^~~~~~
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘uint32_t 
> arrow::SSE4_crc32_u8(uint32_t, uint8_t)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:136:3: error: ‘DCHECK’ was 
> not declared in this scope
>    DCHECK(false) << "SSE support is not enabled";
>    ^~~~~~
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘uint32_t 
> arrow::SSE4_crc32_u16(uint32_t, uint16_t)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:141:3: error: ‘DCHECK’ was 
> not declared in this scope
>    DCHECK(false) << "SSE support is not enabled";
>    ^~~~~~
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘uint32_t 
> arrow::SSE4_crc32_u32(uint32_t, uint32_t)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:146:3: error: ‘DCHECK’ was 
> not declared in this scope
>    DCHECK(false) << "SSE support is not enabled";
>    ^~~~~~
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h: In function ‘uint32_t 
> arrow::SSE4_crc32_u64(uint32_t, uint64_t)’:
> /root/repos/arrow/cpp/src/arrow/util/sse-util.h:151:3: error: ‘DCHECK’ was 
> not declared in this scope
>    DCHECK(false) << "SSE support is not enabled";
> {code}
> By importing `logging.h` or removing `DCHECK`, they can compile. The fix 
> should be to refactor the SSE detection macro out of this file such that the 
> needing code does not need to import this file and only a header with macro 
> detection.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to