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

Segmentation fault: llvm::GetElementPtrInst::getGEPReturnType #57

Open
xaionaro opened this issue Mar 6, 2020 · 0 comments
Open

Segmentation fault: llvm::GetElementPtrInst::getGEPReturnType #57

xaionaro opened this issue Mar 6, 2020 · 0 comments

Comments

@xaionaro
Copy link

xaionaro commented Mar 6, 2020

Hello. I've just built fcd and a Go's hello world, and tried to decompile the hello-world with fcd. As result it's a segfault:

$ cat helloworld.go 
package main
import "fmt"
func main() {
        fmt.Println("Hello, world!")
}
$ go version
go version go1.7.4 linux/amd64
$ go build
$ ~/src/fcd/build/fcd hello
Stack dump:
0.      Optimizing LLVM IR
1.      Running pass 'Identify locals' on module 'hello'.
0  libLLVM-4.0.so.1 0x00007f35f6b7cbc5 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 37
1  libLLVM-4.0.so.1 0x00007f35f6b7ad6e llvm::sys::RunSignalHandlers() + 62
2  libLLVM-4.0.so.1 0x00007f35f6b7ae92
3  libc.so.6        0x00007f35f3495060
4  libLLVM-4.0.so.1 0x00007f35f6c6edb4 llvm::PointerType::get(llvm::Type*, unsigned int) + 20
5  fcd              0x0000000000960b44 llvm::GetElementPtrInst::getGEPReturnType(llvm::Type*, llvm::Value*, llvm::ArrayRef<llvm::Value*>) + 100
6  fcd              0x0000000000a5dd3b llvm::GetElementPtrInst::GetElementPtrInst(llvm::Type*, llvm::Value*, llvm::ArrayRef<llvm::Value*>, unsigned int, llvm::Twine const&, llvm::Instruction*) + 123
7  fcd              0x0000000000a5ce97
8  fcd              0x0000000000a4a530
9  fcd              0x0000000000a48d3b
10 fcd              0x0000000000a48933
11 libLLVM-4.0.so.1 0x00007f35f6c43007 llvm::legacy::PassManagerImpl::run(llvm::Module&) + 759
12 fcd              0x0000000000a21acc
13 fcd              0x0000000000a1f61d main + 2957
14 libc.so.6        0x00007f35f34822e1 __libc_start_main + 241
15 fcd              0x0000000000879b7a _start + 42
Segmentation fault (core dumped)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant