Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fuchsia + lld page-faulting on FnOnce::call_once vtable shim #56089

Closed
cramertj opened this issue Nov 20, 2018 · 2 comments
Closed

Fuchsia + lld page-faulting on FnOnce::call_once vtable shim #56089

cramertj opened this issue Nov 20, 2018 · 2 comments
Labels
A-codegen Area: Code generation O-fuchsia Operating system: Fuchsia T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@cramertj
Copy link
Member

cramertj commented Nov 20, 2018

After the switch to lld, even a minimal Fuchsia binary page-faults at runtime. The backtraces point to the FnOnce::call_once vtable shim added in #54183. I'm not making use of Box<dyn FnOnce> anywhere in Fuchsia directly, but it's possible an std use has snuck in (edit: but it definitely shouldn't be the first function run by the loader?). cc @petrhosek

[00028.682] 09877.09884> PageFault: 473109 free pages
[00028.682] 09877.09884> PageFault: MemoryUsed: proc  1129   10M 'fshost'
[00028.683] 09877.09884> PageFault: MemoryUsed: proc  2945   72M 'blobfs:/blob'
[00028.683] 09877.09884> PageFault: MemoryUsed: proc  3378    8M 'minfs:/data'
[00028.684] 01045.01271> devmgr: crash_analyzer_listener: analyzing exception type 0x108
[00028.684] 01105.01119> <== fatal exception: process ./connectivity_testing_lib_test[9877] thread initial-thread[9884]
[00028.684] 01105.01119> <== fatal page fault, PC at 0x1728953ca000
[00028.684] 01105.01119>  CS:                   0 RIP:     0x1728953ca000 EFL:            0x10202 CR2:         0x4c74dfa5
[00028.684] 01105.01119>  RAX:                  0 RBX:                  0 RCX:                  0 RDX:                  0
[00028.684] 01105.01119>  RSI:     0x79f30ec5a000 RDI:         0x4c74dfa5 RBP:                  0 RSP:      0x1e00e749ff8
[00028.684] 01105.01119>   R8:                  0  R9:                  0 R10:                  0 R11:                  0
[00028.684] 01105.01119>  R12:                  0 R13:                  0 R14:                  0 R15:                  0
[00028.684] 01105.01119>  errc:               0x4
[00028.684] 01105.01119> bottom of user stack:
[00028.684] 01105.01119> 0x000001e00e749ff8: 00000000 00000000                   |................|
[00028.684] 01105.01119> arch: x86_64
[00028.684] 01105.01119> read_mem @0x8 FAILED 8
[00028.684] 01105.01119> {{{reset}}}
[00028.684] 01105.01119> {{{module:0x1e8931d8:<VMO#9844=connectivity_testing_:elf:30922f7ca740fd8a}}}
[00028.684] 01105.01119> {{{mmap:0x1728953a8000:0x22000:load:0x1e8931d8:r:0}}}
[00028.684] 01105.01119> {{{mmap:0x1728953ca000:0x1000:load:0x1e8931d8:rx:0x22000}}}
[00028.684] 01105.01119> {{{mmap:0x1728953cb000:0x2000:load:0x1e8931d8:rw:0x23000}}}
[00028.684] 01105.01119> {{{module:0x1e8931d9:<VMO#1033=vdso/full>:elf:329e77f0c225f0f29e7d914d7bf2c55f89f90f43}}}
[00028.684] 01105.01119> {{{mmap:0x79f30ec[28.682] 09877.09884> 5a000:0x6000:load:0x1e8931d9:r:0}}}
[00028.684] 01105.01119> {{{mmap:0x79f30ec60000:0x1000:load:0x1e8931d9:rx:0x6000}}}
[00028.684] 01105.01119> bt#01: pc 0x1728953ca000 sp 0x1e00e749fPageFault: 473109 free pagesf8
[00028.684] 01105.01119> bt#02: end
[00028.684] 01105.01119>
 {{{bt:1:0x1728953ca000}}}
[28.682] 09877.09884> PageFault: MemoryUsed: proc  1129   10M 'fshost'
[28.683] 09877.09884> PageFault: MemoryUsed: proc  2945   72M 'blobfs:/blob'
[28.683] 09877.09884> PageFault: MemoryUsed: proc  3378    8M 'minfs:/data'
[28.684] 01045.01271> devmgr: crash_analyzer_listener: analyzing exception type 0x108
[28.684] 01105.01119> <== fatal exception: process ./connectivity_testing_lib_test[9877] thread initial-thread[9884]
[28.684] 01105.01119> <== fatal page fault, PC at 0x1728953ca000
[28.684] 01105.01119> CS:                   0 RIP:     0x1728953ca000 EFL:            0x10202 CR2:         0x4c74dfa5
[28.684] 01105.01119> RAX:                  0 RBX:                  0 RCX:                  0 RDX:                  0
[28.684] 01105.01119> RSI:     0x79f30ec5a000 RDI:         0x4c74dfa5 RBP:                  0 RSP:      0x1e00e749ff8
[28.684] 01105.01119> R8:                  0  R9:                  0 R10:                  0 R11:                  0
[28.684] 01105.01119> R12:                  0 R13:                  0 R14:                  0 R15:                  0
[28.684] 01105.01119> errc:               0x4
[28.684] 01105.01119> bottom of user stack:
[28.684] 01105.01119> 0x000001e00e749ff8: 00000000 00000000                   |................|
[28.684] 01105.01119> arch: x86_64
[28.684] 01105.01119> read_mem @0x8 FAILED 8
[28.684] 01105.01119> bt#01: pc 0x1728953ca000 sp 0x1e00e749ff8
[28.684] 01105.01119> bt#02: end
[28.684] 01105.01119>    #1    0x00001728953ca000 in core::ops::function::FnOnce::call_once::_$u7b$$u7b$vtable.shim$u7d$$u7d$::h10568ef9220c4b73 /b/s/w/ir/kitchen-workdir/rust/src/libcore/ops/function.rs:238 <<VMO#9844=connectivity_testing_>+0x22000
@jonas-schievink jonas-schievink added A-codegen Area: Code generation T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. O-fuchsia Operating system: Fuchsia labels Jan 27, 2019
@workingjubilee
Copy link
Member

Checking in: Is this still an issue in 2022?

@petrhosek
Copy link
Contributor

I don't think so, it should be safe to close this.

@Mark-Simulacrum Mark-Simulacrum closed this as not planned Won't fix, can't repro, duplicate, stale Jul 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-codegen Area: Code generation O-fuchsia Operating system: Fuchsia T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

5 participants