summaryrefslogtreecommitdiff
path: root/runtime/base/bit_struct.h
AgeCommit message (Collapse)Author
2018-03-05Move most of runtime/base to libartbase/base David Sehr
Enforce the layering that code in runtime/base should not depend on runtime by separating it into libartbase. Some of the code in runtime/base depends on the Runtime class, so it cannot be moved yet. Also, some of the tests depend on CommonRuntimeTest, which itself needs to be factored (in a subsequent CL). Bug: 22322814 Test: make -j 50 checkbuild make -j 50 test-art-host Change-Id: I8b096c1e2542f829eb456b4b057c71421b77d7e2
2018-02-28Header library to remove dependence on runtime/ David Sehr
Add a new header library to remove libdexfile and others' dependence on runtime (typically runtime/base) includes in libdexfile. Also a small step to tease dexlayout and profman away from relying on these as well. Bug: 22322814 Test: make -j 50 checkbuild make -j 50 test-art-host-gtest Change-Id: I38e2fe399a75f4bc6318c77a71954c00ea73ec2b
2017-11-16cpplint: Remove many unnecessary NOLINT Igor Murashkin
Now that we updated to upstream cpplint, a lot of these NOLINTs are no longer necessary. Bug: 68951293 Change-Id: If8ed5ffe89727f313f907a214b6d8fd2a2eddbad
2017-10-27base: Fix bitstruct bug with assigning fields Igor Murashkin
Given a BitStruct 'foo', where bar was a BitStructField, assignment was broken because it was using the C++ default behavior (copy the entire word). foo.bar = other_foo.bar This will now correctly use BitFieldInsert to update the 'bar' bitfield. Change-Id: I1464462ffd4df22ad14a2e43a34f74d75ac2809a
2017-10-07Revert "Revert "base: Add more bit utils and bit struct class"" Igor Murashkin
This reverts commit 5e008b3c5a907015116aa95623205ac8fc2c6768. Change-Id: I05d26dd4a1f8d35e4377f65e209587b67b2ca04e
2017-10-07Revert "base: Add more bit utils and bit struct class" Nicolas Geoffray
Tests fail on device. This reverts commit c60f75d6d6f229fa7b5494d54189e974883dafa2. Change-Id: I2d8f919df154b700854d78993c460e3aab7cf0c3
2017-10-06base: Add more bit utils and bit struct class Igor Murashkin
Allows efficient, zero-cost, bitwise memory storage. // Definition for type 'Example' BITSTRUCT_DEFINE_START(Example, 10) BitStructUint<0, 2> u2; // Every field must be a BitStruct[*]. BitStructInt<2, 7> i7; BitStructUint<9, 1> i1; BITSTRUCT_DEFINE_END(Example); Would define a bit struct with this layout: <- 1 -> <-- 7 --> <- 2 -> +--------+---------------+-----+ | i1 | i7 | u2 + +--------+---------------+-----+ 10 9 2 0 See bit_struct.h for more documentation. (Also adds new BitField[Extract|Insert|Clear] bit_utils similar to the ARM bitfield instructions). Test: art/test.py --gtest Change-Id: I5e43f2468c5d275ee872546855527bb4ea73ad4c