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

gapis crashes when opening a trace file #1548

Closed
xyzz opened this issue Jan 16, 2018 · 3 comments
Closed

gapis crashes when opening a trace file #1548

xyzz opened this issue Jan 16, 2018 · 3 comments

Comments

@xyzz
Copy link

xyzz commented Jan 16, 2018

GAPID Version: 1.0.1:developer
OS: linux amd64 (archlinux)

Log:

panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: Panic at command 179:eglMakeCurrent(display: 1, draw: 0x9c4791a0, read: 0x9c4791a0, context: 0x9c47ad80) → 1:
runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: Panic at command 179:eglMakeCurrent(display: 1, draw: 0x9c4791a0, read: 0x9c4791a0, context: 0x9c47ad80) → 1:
runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x161f20a]

goroutine 21 [running]:
github.com/google/gapid/core/app/crash.Crash(0x2924940, 0xc4222c8500)
	/home/xyz/go/src/github.com/google/gapid/core/app/crash/crash.go:89 +0xb4
github.com/google/gapid/core/app/crash.handler()
	/home/xyz/go/src/github.com/google/gapid/core/app/crash/crash.go:56 +0x52
panic(0x2924940, 0xc4222c8500)
	/home/xyz/go-1.8.5/src/runtime/panic.go:489 +0x2cf
github.com/google/gapid/gapis/api.ForeachCmd.func1(0xc42121d968, 0xc42121d990)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/cmd_foreach.go:39 +0x16c
panic(0x2a15000, 0x48bde00)
	/home/xyz/go-1.8.5/src/runtime/panic.go:489 +0x2cf
github.com/google/gapid/gapis/api/gles.subGetCapability.func1(0xbe2, 0xc42015f800, 0x0, 0xc42121ce38)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/mutate.go:3471 +0x11a
github.com/google/gapid/gapis/api/gles.subGetCapability(0x491d260, 0xc421967950, 0x493dca0, 0xc42121ce38, 0x40000000000000b3, 0x0, 0xc421f4e300, 0xc42045aba0, 0x9c719930, 0x0, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/mutate.go:3507 +0x1bd
github.com/google/gapid/gapis/api/gles.(*tweaker).getCapability(0xc422268640, 0x491d260, 0xc421967950, 0xbe2, 0x2d0f3e0)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/tweaker.go:69 +0x163
github.com/google/gapid/gapis/api/gles.(*tweaker).glDisable(0xc422268640, 0x491d260, 0xc421967950, 0xbe2)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/tweaker.go:87 +0x4b
github.com/google/gapid/gapis/api/gles.drawUndefinedFramebuffer(0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000, 0x49a99e0, 0xc421f4e300, 0xc42015f800, 0x48e65e0, 0xc4219ba630, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/undefined_framebuffer.go:96 +0x102
github.com/google/gapid/gapis/api/gles.undefinedFramebuffer.func1(0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000, 0x48e65e0, 0xc4219ba630)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/undefined_framebuffer.go:39 +0x32b
github.com/google/gapid/gapis/api/transform.transform.Transform(0x2f45b31, 0x10, 0xc421e334c0, 0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000, 0x48e65e0, 0xc4219ba630)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/transforms.go:75 +0x75
github.com/google/gapid/gapis/api/transform.(*transform).Transform(0xc421e334e0, 0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000, 0x48e65e0, 0xc4219ba630)
	<autogenerated>:15 +0xb1
github.com/google/gapid/gapis/api/transform.TransformWriter.MutateAndWrite(0xc421f4e300, 0x48e6620, 0xc421e334e0, 0x48e65e0, 0xc4219ba630, 0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/transforms.go:98 +0x83
github.com/google/gapid/gapis/api/transform.(*TransformWriter).MutateAndWrite(0xc4219ba660, 0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000)
	<autogenerated>:13 +0xa1
github.com/google/gapid/gapis/api/gles.(*findIssues).Transform(0xc42232cbe0, 0x491d260, 0xc421967950, 0xb3, 0x492e0a0, 0xc4203c4000, 0x48e65e0, 0xc4219ba660)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/find_issues.go:118 +0x1ee
github.com/google/gapid/gapis/api/transform.TransformWriter.MutateAndWrite(0xc421f4e300, 0x48e3fe0, 0xc42232cbe0, 0x48e65e0, 0xc4219ba660, 0x491d260, 0xc4219baf60, 0xb3, 0x492e0a0, 0xc4203c4000)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/transforms.go:98 +0x83
github.com/google/gapid/gapis/api/transform.(*TransformWriter).MutateAndWrite(0xc4219ba690, 0x491d260, 0xc4219baf60, 0xb3, 0x492e0a0, 0xc4203c4000)
	<autogenerated>:13 +0xa1
github.com/google/gapid/gapis/api/transform.(*DeadCodeElimination).Flush.func1(0x491d260, 0xc4219baf60, 0xb3, 0x492e0a0, 0xc4203c4000, 0x0, 0x0)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/dead_code_elimination.go:84 +0x7f
github.com/google/gapid/gapis/api.ForeachCmd(0x491d260, 0xc4219645a0, 0xc421b00000, 0x3b82, 0x3c00, 0xc42121da20, 0x0, 0x0)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/cmd_foreach.go:46 +0x145
github.com/google/gapid/gapis/api/transform.(*DeadCodeElimination).Flush(0xc421e33420, 0x491d260, 0xc4219645a0, 0x48e65e0, 0xc4219ba690)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/dead_code_elimination.go:86 +0x26a
github.com/google/gapid/gapis/api/transform.Transforms.Transform(0xc422314d00, 0x5, 0x8, 0x491d260, 0xc4219645a0, 0xc420393c48, 0x0, 0x0, 0x48e43e0, 0xc4223e02c0)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/transform/transforms.go:44 +0x32c
github.com/google/gapid/gapis/api/gles.API.Replay(0x491d260, 0xc421964330, 0xc422154010, 0xc422154008, 0x2a11b20, 0x52a56a0, 0xc4223e2020, 0x1, 0x1, 0x49a99e0, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/api/gles/replay.go:223 +0xeec
github.com/google/gapid/gapis/api/gles.(*API).Replay(0x52a56a0, 0x491d260, 0xc421964330, 0xc422154010, 0xc422154008, 0x2a11b20, 0x52a56a0, 0xc4223e2020, 0x1, 0x1, ...)
	<autogenerated>:4419 +0xfb
github.com/google/gapid/gapis/replay.(*Manager).execute.func1()
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/batch.go:153 +0x18c
github.com/google/gapid/core/app/benchmark.(*DurationCounter).Time(0xc4201ba760, 0xc420394258)
	/home/xyz/go/src/github.com/google/gapid/core/app/benchmark/counter.go:163 +0x7b
github.com/google/gapid/gapis/replay.(*Manager).execute(0xc4203600c0, 0x491d260, 0xc421964330, 0x48e8ca0, 0xc420358820, 0x94b62b25643ab952, 0x675c650b91e372a8, 0x5adde611f00ab552, 0x80ef50e2f5001aa5, 0xaa4b6ba9e1aebdd6, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/batch.go:154 +0x9e4
github.com/google/gapid/gapis/replay.(*Manager).batch.func1(0x48e8ca0, 0xc420358820, 0xc4203945f8, 0xf5001aa55adde611, 0xe1aebdd680ef50e2, 0x643ab952aa4b6ba9, 0x91e372a894b62b25, 0xf00ab552675c650b, 0x2a11b20, 0x52a56a0, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/batch.go:82 +0x4b3
github.com/google/gapid/gapis/replay.(*Manager).batch(0xc4203600c0, 0x491d260, 0xc421964090, 0xc4223e2000, 0x1, 0x1, 0x2b7d6c0, 0xc421251780, 0x2c79f20, 0xc4206f97c0, ...)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/batch.go:83 +0x33c
github.com/google/gapid/gapis/replay.(*Manager).(github.com/google/gapid/gapis/replay.batch)-fm(0x491d260, 0xc420355110, 0xc4223e2000, 0x1, 0x1, 0x2b7d6c0, 0xc421251780, 0x2c79f20, 0xc4206f97c0, 0x0)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/manager.go:126 +0x93
github.com/google/gapid/gapis/replay/scheduler.(*bin).exec(0xc420363900, 0x491d260, 0xc420355110, 0xc420358990)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/scheduler/scheduler.go:243 +0x2d8
github.com/google/gapid/gapis/replay/scheduler.(*Scheduler).run(0xc4203a2fc0, 0x491d260, 0xc420355110)
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/scheduler/scheduler.go:176 +0x469
github.com/google/gapid/gapis/replay/scheduler.New.func1()
	/home/xyz/go/src/github.com/google/gapid/gapis/replay/scheduler/scheduler.go:73 +0x3c
github.com/google/gapid/core/app/crash.Go.func1(0xc4203a2fe0)
	/home/xyz/go/src/github.com/google/gapid/core/app/crash/crash.go:65 +0x43
created by github.com/google/gapid/core/app/crash.Go
	/home/xyz/go/src/github.com/google/gapid/core/app/crash/crash.go:66 +0x3f

Trace file: trace.zip

@ben-clayton
Copy link
Contributor

Hi @xyzz,

Thank you for your bug report.
I'm working on fixing the crash reported, but it appears that your application is using OpenGL ES 1.0 commands. Unfortunately GAPID currently only supports OpenGL ES 2.0 onwards, so even with the fix, GAPID will be of limited use for this particular app.

Many thanks,
Ben

@xyzz
Copy link
Author

xyzz commented Jan 16, 2018

Thanks for your reply.

Do you have a suggestion for a tool that's supported and can trace opengl es 1 commands on Android?

@ben-clayton
Copy link
Contributor

Do you have a suggestion for a tool that's supported and can trace opengl es 1 commands on Android?

I'm afraid not. We currently do not support OpenGL ES 1.x as all Android devices have supported OpenGL ES 2.0 since Android 2.2 (released 7 years ago) and there were major API breaking changes between OpenGL ES 1.x and 2.0. Supporting OpenGL ES 1.x would require significant work and we believe the significant majority of developers will be targeting OpenGL ES 2.0 onwards or Vulkan.

Sorry for the bad news!

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

2 participants