Yan-Daojiang has uploaded this change for review. ( 
http://gerrit.cloudera.org:8080/22515


Change subject: fix(cbtree-test): ensure proper alignment of `version_` in 
`NodeBase` on ARM64
......................................................................

fix(cbtree-test): ensure proper alignment of `version_` in `NodeBase` on ARM64

In the `TestCBTree.TestLeafNode` test case, a SIGBUS error occurs on ARM64
when accessing the `version_` field in the `NodeBase` structure. This is
due to the `PACKED` attribute causing misalignment of the `version_` field,
which is a `uint64_t`. On ARM64, unaligned access to 8-byte data triggers
a SIGBUS, whereas x86 platforms can handle such accesses without crashing.

This commit fixes the issue by ensuring proper alignment of the `version_`
field, preventing the SIGBUS error on ARM64 platforms.

Stack trace:
    *** SIGBUS (@0xffffe8a2195f) received by PID 11971 (TID 0xffffa8b80040)
    from PID 18446744073317521759; stack trace: ***
    @     0xffffa920e890 google::(anonymous namespace)::FailureSignalHandler()
    @     0xffffaa6607a0 ([vdso]+0x79f)
    @           0x26d950 base::subtle::Acquire_Load()
    @           0x269390 kudu::tablet::btree::VersionField::Lock()
    @           0x26f540 kudu::tablet::btree::NodeBase<>::Lock()
    @           0x267dbc kudu::tablet::btree::TestCBTree::InsertInLeaf<>()
    @           0x25b1e8 
kudu::tablet::btree::TestCBTree_TestLeafNode_Test::TestBody()

Change-Id: Id082d3ca243418d4f0016fbd21a59ead0fa9dfc5
---
M src/kudu/tablet/concurrent_btree.h
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/15/22515/1
--
To view, visit http://gerrit.cloudera.org:8080/22515
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Id082d3ca243418d4f0016fbd21a59ead0fa9dfc5
Gerrit-Change-Number: 22515
Gerrit-PatchSet: 1
Gerrit-Owner: Yan-Daojiang <[email protected]>

Reply via email to