mirror of
https://github.com/apache/impala.git
synced 2025-12-30 03:01:44 -05:00
Currently, class PerFilterState is marked with CACHELINE_ALIGNED, which is actually a macro definition of __attribute__((aligned())). For static allocation, it can specify memory alignment, but it cannot specify alignment for dynamic memory allocation. In the code, all PerFilterState objects are dynamically created using make_unique in the function RuntimeFilterBank::BuildFilterMap(), so CACHELINE_ALIGNED does not really have any effect. It might even lead to unexpected situations as described in the JIRA comments. Therefore, this patch replaces CACHELINE_ALIGNED with CacheLineAligned, which supports alignment for dynamic memory allocation. Testing: - Existing tests cover this change. Change-Id: I0d119679b1d446cb69f6eec595def2d40cb6d1ff Reviewed-on: http://gerrit.cloudera.org:8080/22147 Reviewed-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com> Tested-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com>