Opened 6 years ago
Last modified 4 years ago
#14366 new bug
haiku_loader / BIOS: Unaligned pointer from packed class or structure
Reported by: | kallisti5 | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | System/Boot Loader/BIOS | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
/home/kallisti5/Code/haiku/src/system/boot/platform/bios_ia32/mmu.cpp:729:7: warning: taking address of packed member 'num_physical_memory_ranges' of class or structure 'kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] &gKernelArgs.num_physical_memory_ranges, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/platform/bios_ia32/long.cpp:98:37: warning: taking address of packed member 'phys_pgdir' of class or structure 'arch_kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] pml4 = (uint64*)mmu_allocate_page(&gKernelArgs.arch_args.phys_pgdir); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ C++ /home/kallisti5/Code/haiku/generated.clang.x86_64/objects/haiku/x86_64/release/system/boot/loader/bios_ia32/elf.o /home/kallisti5/Code/haiku/src/system/boot/loader/elf.cpp:302:29: warning: taking address of packed member 'start' of class or structure 'elf64_region' may result in an unaligned pointer value [-Waddress-of-packed-member] if (Class::AllocateRegion(&firstRegion->start, totalSize, ^~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/loader/elf.cpp:662:24: note: in instantiation of member function 'ELFLoader<ELF64Class>::Load' requested here return ELF64Loader::Load(fd, *_image); ^ /home/kallisti5/Code/haiku/src/system/boot/loader/elf.cpp:302:29: warning: taking address of packed member 'start' of class or structure 'elf32_region' may result in an unaligned pointer value [-Waddress-of-packed-member] if (Class::AllocateRegion(&firstRegion->start, totalSize, ^~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/loader/elf.cpp:672:24: note: in instantiation of member function 'ELFLoader<ELF32Class>::Load' requested here return ELF32Loader::Load(fd, *_image); ^ 2 warnings generated. C++ /home/kallisti5/Code/haiku/generated.clang.x86_64/objects/haiku/x86_64/release/system/boot/loader/bios_ia32/kernel_args.o /home/kallisti5/Code/haiku/src/system/boot/loader/kernel_args.cpp:33:4: warning: taking address of packed member 'num_kernel_args_ranges' of class or structure 'kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] &gKernelArgs.num_kernel_args_ranges, MAX_KERNEL_ARGS_RANGE, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/loader/kernel_args.cpp:279:4: warning: taking address of packed member 'num_physical_memory_ranges' of class or structure 'kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] &gKernelArgs.num_physical_memory_ranges, MAX_PHYSICAL_MEMORY_RANGE, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/loader/kernel_args.cpp:288:4: warning: taking address of packed member 'num_physical_allocated_ranges' of class or structure 'kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] &gKernelArgs.num_physical_allocated_ranges, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/kallisti5/Code/haiku/src/system/boot/loader/kernel_args.cpp:297:4: warning: taking address of packed member 'num_virtual_allocated_ranges' of class or structure 'kernel_args' may result in an unaligned pointer value [-Waddress-of-packed-member] &gKernelArgs.num_virtual_allocated_ranges, MAX_VIRTUAL_ALLOCATED_RANGE, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 warnings generated.
clang warning us about these... could be an issue.
Change History (5)
comment:1 by , 6 years ago
Summary: | haiku_loader / BIOS: Unaligned porinter from packed class or structure → haiku_loader / BIOS: Unaligned pointer from packed class or structure |
---|
comment:2 by , 5 years ago
Component: | System/Boot Loader → System/Boot Loader/BIOS |
---|
comment:3 by , 4 years ago
Note:
See TracTickets
for help on using tickets.
Happens with GCC11.1 buildtools :