Repository navigation
Commit 6cdbb0e
committed
fs: optimize out 16 bytes worth of padding in struct inode
Rearrange the fields in struct inode so that on an x86_64 system,
fields that require 8-byte alignment don't end up causing 4-byte holes
in the structure. It reduces the size of struct inode from 568 bytes
to 552 bytes.
Also move the fields protected by i_lock (i_blocks, i_bytes, and
i_size) into the same cache line as i_lock.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>1 parent 80e675f commit 6cdbb0e
1 file changed
Lines changed: 5 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
771 | 771 | | |
772 | 772 | | |
773 | 773 | | |
774 | | - | |
775 | 774 | | |
776 | 775 | | |
777 | 776 | | |
778 | | - | |
| 777 | + | |
| 778 | + | |
779 | 779 | | |
| 780 | + | |
780 | 781 | | |
781 | 782 | | |
782 | 783 | | |
783 | 784 | | |
784 | 785 | | |
785 | 786 | | |
786 | 787 | | |
787 | | - | |
788 | 788 | | |
789 | 789 | | |
790 | 790 | | |
| |||
798 | 798 | | |
799 | 799 | | |
800 | 800 | | |
| 801 | + | |
801 | 802 | | |
802 | | - | |
803 | 803 | | |
| 804 | + | |
804 | 805 | | |
805 | 806 | | |
806 | 807 | | |
| |||
824 | 825 | | |
825 | 826 | | |
826 | 827 | | |
827 | | - | |
828 | 828 | | |
829 | 829 | | |
830 | 830 | | |
| |||
0 commit comments