aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/objdump
AgeCommit message (Collapse)Author
2021-04-30cmd/internal/objfile: emit better error for Go object of a different versionCherry Zhang
The Go object file format can change from version to version. Tools like cmd/objdump and cmd/nm only onderstand the current version of the object file. Currently, when it encounters an object built with a different version of the toolchain, it emits a generic error "unrecognized object file", which is not very helpful for users. This CL makes it emit a clearer error. Now it emits objdump: open go116.o: go object of a different version: go116ld Change-Id: I063c6078ed1da78f97cea65796779ae093a1a8cb Reviewed-on: https://go-review.googlesource.com/c/go/+/315609 Trust: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Than McIntosh <thanm@google.com>
2021-04-09cmd/objdump: update test with register ABICherry Zhang
With register ABI, the disassembly of the function may not contain a "movq" instruction (which used to be e.g. storing arguments to stack). Look for "jmp" instruction instead. This is also in consistent with the test for Go assembly syntax. Change-Id: Ifc9e48bbc4f85c4e4aace5981b3a0f8ae925f6d6 Reviewed-on: https://go-review.googlesource.com/c/go/+/308652 Trust: Cherry Zhang <cherryyz@google.com> Reviewed-by: Than McIntosh <thanm@google.com>
2021-01-11cmd/internal/objfile: don't require runtime.symtab symbol for XCOFFCherry Zhang
For some reason (that I didn't look into), externally linked AIX binaries don't have runtime.symtab symbol. Since recent Go releases (Go 1.3 maybe?), that symbol is empty and not necessary anyway. Don't require it. Fixes #40972. Change-Id: I73a1f0142195ea6debdba8a4f6e12cadc3980dc5 Reviewed-on: https://go-review.googlesource.com/c/go/+/279995 Trust: Cherry Zhang <cherryyz@google.com> Reviewed-by: Than McIntosh <thanm@google.com>
2020-12-09all: update to use os.ReadFile, os.WriteFile, os.CreateTemp, os.MkdirTempRuss Cox
As part of #42026, these helpers from io/ioutil were moved to os. (ioutil.TempFile and TempDir became os.CreateTemp and MkdirTemp.) Update the Go tree to use the preferred names. As usual, code compiled with the Go 1.4 bootstrap toolchain and code vendored from other sources is excluded. ReadDir changes are in a separate CL, because they are not a simple search and replace. For #42026. Change-Id: If318df0216d57e95ea0c4093b89f65e5b0ababb3 Reviewed-on: https://go-review.googlesource.com/c/go/+/266365 Trust: Russ Cox <rsc@golang.org> Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2020-10-16cmd/objdump: skip TestDisasmExtld on AIXCherry Zhang
Fixes #42025. Change-Id: I34bed3364902e37df24ed6f56cddf163c7a4dc52 Reviewed-on: https://go-review.googlesource.com/c/go/+/263147 Trust: Cherry Zhang <cherryyz@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org> Reviewed-by: Than McIntosh <thanm@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org>
2020-10-16cmd/objdump: skip tests on unsupported platformsCherry Zhang
Should fix mips(64)(le) and s390x builds. Change-Id: I2c80339ce22b0ce5dceb595e504740e74bc840cd Reviewed-on: https://go-review.googlesource.com/c/go/+/263137 Trust: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-10-16cmd/internal/objfile: correct file table reading for Go object fileCherry Zhang
Apparently I never actually understood the new file table in Go object files. The PC value stream actually encodes the file index in the per-CU table. I thought it was indexing into a per-function table, which then contains index to the per-CU table. Remove the extra indirection. Change-Id: I0aea5629f7b3888ebe3a04fea437aa15ce89519e Reviewed-on: https://go-review.googlesource.com/c/go/+/262779 Trust: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-08-22cmd/objdump: skip cgo test in testGoAndCgoDisasm on AIXAlex Brainman
Updates #40972. Change-Id: Id2092f0bef4fb4bdc4178e7bc9730716136f7b8a Reviewed-on: https://go-review.googlesource.com/c/go/+/249760 Run-TryBot: Alex Brainman <alex.brainman@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-08-22cmd/internal/objfile: use pe.FileHeader.Machine to reliably determine GOARCHAlex Brainman
Current peFile.goarch looks for symbols like "_rt0_386_windows" to determine GOARCH. But "_rt0_386_windows" is not present in executables built with cgo. Use pe.FileHeader.Machine instead. This should work with any Windows executable, not just with Go built executable. Fixes #39682 Change-Id: Ie0ffce664f4b8b8fed69b2ecc482425b042a38d5 Reviewed-on: https://go-review.googlesource.com/c/go/+/240957 Run-TryBot: Alex Brainman <alex.brainman@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com>
2020-06-09cmd/dist: do not unset GOROOT_FINAL prior to running testsBryan C. Mills
Also do not unset it by default in the tests for cmd/go. GOROOT_FINAL affects the GOROOT value embedded in binaries, such as 'cmd/cgo'. If its value changes and a build command is performed that depends on one of those binaries, the binary would be spuriously rebuilt. Instead, only unset it in the specific tests that make assumptions about the GOROOT paths embedded in specific compiled binaries. That may cause those tests to do a little extra rebuilding when GOROOT_FINAL is set, but that little bit of extra rebuilding seems preferable to spuriously-stale binaries. Fixes #39385 Change-Id: I7c87b1519bb5bcff64babf1505fd1033ffa4f4fb Reviewed-on: https://go-review.googlesource.com/c/go/+/236819 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-06-03Revert "cmd/internal/goobj: add index to symbol name for indexed symbols"Cherry Zhang
This reverts CL 229246. For new indexed object files, in CL 229246 we added symbol index to tools (nm, objdump) output. This affects external tools that parse those outputs. And the added index doesn't look very nice. In this release we take it out. For future releases we may introduce a flag to tools (nm, objdump) and optionally dump the symbol index. For refererenced (not defined) indexed symbols, currently the symbol is still referenced only by index, not by name. The next CL will make the object file self-contained, so tools can dump the symbol names properly (as before). For #38875. Change-Id: I07375e85a8e826e15c82fa452d11f0eaf8535a00 Reviewed-on: https://go-review.googlesource.com/c/go/+/236167 Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-04-22[dev.link] cmd/internal/goobj: add index to symbol name for indexed symbolsCherry Zhang
With old object files, when objdump an object file which, for example, contains a call of fmt.Fprintf, it shows a symbol reference like R_CALL:fmt.Fprintf With new object files, as the symbol reference is indexed, the reference becomes R_CALL:fmt.#33 The object file does not contain information of what symbol #33 in the fmt package is. To make this more useful, print the index when dumping the symbol definitions. This way, when dumping the fmt package, e.g. "go tool nm fmt.a", it will print 6c705 T fmt.Fprintf#33 So we can find out what symbol #33 actually is. Change-Id: I320776597d28615ce18dd0617c352d2b8180db49 Reviewed-on: https://go-review.googlesource.com/c/go/+/229246 Reviewed-by: Austin Clements <austin@google.com> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-03-30cmd/objdump: test disassembly on ARM and ARM64Cherry Zhang
We support disassembly on both ARM and ARM64. Tests are only enabled on one or the other. This CL enables both. Change-Id: If89d78b975c241c2b14f72b714dcdc771b4b382c Reviewed-on: https://go-review.googlesource.com/c/go/+/226459 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: David Chase <drchase@google.com>
2020-03-30cmd/objdump: add support for -gnu option on Go objdumpLynn Boger
This adds support for the -gnu option on Go objdump. When this option is used, then output will include gnu assembly in comments alongside the Go assembly. The objdump test was updated to test this new option. This option is supported for the arches found in golang.org/x that provide the GNUsyntax function. Updates #34372 Change-Id: I9e60e1691526607dda3c857c4564dcef408b8391 Reviewed-on: https://go-review.googlesource.com/c/go/+/225459 Run-TryBot: Lynn Boger <laboger@linux.vnet.ibm.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
2020-03-12cmd/objdump: guard against out-of-range lines from directives.David Chase
//line bogo.go:9999999 will cause 'go tool objdump' to crash unless bogo.go has that many lines. Guard the array index and return innocuous values (nil, nil) from the file cache. Fixes #36683 Change-Id: I4a9f8444dc611654d270cc876e8848dfd2f84770 Reviewed-on: https://go-review.googlesource.com/c/go/+/223081 Run-TryBot: David Chase <drchase@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
2020-01-25cmd/objdump: disable unsupported tests on riscv64Joel Sing
Updates #27532, #36738 and #36739. Change-Id: If10031c6fd2c8ec2aa8c37f7edb148d8f26f8697 Reviewed-on: https://go-review.googlesource.com/c/go/+/216258 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2020-01-17cmd/compile: change the "bogus line" to be 1David Chase
The previous value was "too bogus" and caused objdump to crash. Updated infinite loop test results (only run if -args -f) in ssa/debug_test.go Probably also fixes #36621 but that bug needs more info to tell for certain. Fixes #36570 Change-Id: I51144641d25d559308a98d726d87806bd340cc5a Reviewed-on: https://go-review.googlesource.com/c/go/+/215297 Run-TryBot: David Chase <drchase@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
2019-12-04cmd/objdump: reference tracking bug in TestDisasmCode skip messageTobias Klauser
Issue #12559 was closed and split into #19158 for mips{,le} and #19156 for mips64{,le}. Instead of referencing the individual GOARCH-specific issues in the skip test messages of TestDisasmCode use the tracking bug Change-Id: I6929d25f4ec5aef4f069b7692c4e29106088ce65 Reviewed-on: https://go-review.googlesource.com/c/go/+/209817 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-10-09Revert "cmd/go: fail if a test binary exits with no output"Bryan C. Mills
This reverts CL 184457. Reason for revert: introduced failures in the regression test for #18153. Fixes #34791 Updates #29062 Change-Id: I4040965163f809083c023be055e69b1149d6214e Reviewed-on: https://go-review.googlesource.com/c/go/+/200106 Run-TryBot: Bryan C. Mills <bcmills@google.com> Reviewed-by: Alexander Rakoczy <alex@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-09cmd/go: fail if a test binary exits with no outputDaniel Martí
For example, if a test calls os.Exit(0), that could trick a 'go test' run into not running some of the other tests, and thinking that they all succeeded. This can easily go unnoticed and cause developers headaches. Add a simple sanity check as part of 'go test': if the test binary succeeds and doesn't print anything, we should error, as something clearly went very wrong. This is done by inspecting each of the stdout writes from the spawned process, since we don't want to read the entirety of the output into a buffer. We need to introduce a "buffered" bool var, as there's now an io.Writer layer between cmd.Stdout and &buf. A few TestMain funcs in the standard library needed fixing, as they returned without printing anything as a means to skip testing the entire package. For that purpose add testenv.MainMust, which prints a warning and prints SKIP, similar to when -run matches no tests. Finally, add tests for both os.Exit(0) and os.Exit(1), both as part of TestMain and as part of a single test, and test that the various stdout modes still do the right thing. Fixes #29062. Change-Id: Ic6f8ef3387dfc64e4cd3e8f903d7ca5f5f38d397 Reviewed-on: https://go-review.googlesource.com/c/go/+/184457 Run-TryBot: Daniel Martí <mvdan@mvdan.cc> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-05-13cmd/objdump: ensure that test executable files are distinctJosh Bleecher Snyder
This fixes test failures introduced by CL 176901. Change-Id: I133299ba3be3a15ced076c95e4833ba6070d7eb7 Reviewed-on: https://go-review.googlesource.com/c/go/+/176903 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-05-13cmd/objdump: mark tests as parallelJosh Bleecher Snyder
Speeds up go test -short -count=1 cmd/objdump on my machine from 1.7s to 1.3s. Not much, but as the backpacking saying goes, take care of the ounces and the pounds will take care of themselves. Updates #26473 Change-Id: I59fe9a179e48537c7d82cbba72cde9f92b42a029 Reviewed-on: https://go-review.googlesource.com/c/go/+/176901 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-04-24cmd: re-enable tests with external linking on openbsd/armJoel Sing
Go on openbsd/arm has supported external linking for a while now, so re-enable the external linking related tests that were previously disabled. Fixes #10619 Change-Id: I304eeabf3b462d53b7feda17ae390bbe2fa22069 Reviewed-on: https://go-review.googlesource.com/c/go/+/173597 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-03-08internal/testenv: remove SetModVendorBryan C. Mills
It turns out not to be necessary. Russ expressed a preference for avoiding module fetches over making 'go mod tidy' work within std and cmd right away, so for now we will make the loader use the vendor directory for the standard library even if '-mod=vendor' is not set explicitly. Updates #30228 Change-Id: Idf7208e63da8cb7bfe281b93ec21b61d40334947 Reviewed-on: https://go-review.googlesource.com/c/go/+/166357 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
2019-03-05all: add -mod=vendor to GOFLAGS in tests that execute 'go' commands within ↵Bryan C. Mills
std or cmd Updates #30228 Updates #30240 Updates #30241 Change-Id: Idc311ba77e99909318b5b86f8ef82d4878f73e47 Reviewed-on: https://go-review.googlesource.com/c/go/+/165378 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
2018-08-21cmd/objdump: defer closing the file after openingMuhammad Falak R Wani
Remove the os.Exit(0) to honor the deferred closing of the file. Change-Id: Iaa9304d8203c8fec0ec728af669a94eadd36905c Reviewed-on: https://go-review.googlesource.com/118915 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
2017-11-10cmd/objdump: pass the correct execution mode to x86asm.Decode in disasm_x86 ↵Hiroshi Ioka
on 386 Fixes #22093 Fixes #19988 Change-Id: Ibd8ec89e091fd527f363999e484676931d7aa6e2 Reviewed-on: https://go-review.googlesource.com/67450 Reviewed-by: Keith Randall <khr@golang.org> Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2017-11-01cmd/internal/goobj: accept int64 in readIntCherry Zhang
The counter part, writeInt in cmd/internal/obj, writes int64s. So the reader side should also read int64s. This may cause a larger range of values being accepted, some of which should not be that large. This is probably ok: for example, for size/index/length, the very large value (due to corruption) may be well past the end and causes other errors. And we did not do much bound check anyway. One exmaple where this matters is ARM32's object file. For one type of relocation it encodes the instruction into Reloc.Add field (which itself may be problematic and worth fix) and the instruction encoding overflows int32, causing ARM32 object file being rejected by goobj (and so objdump and nm) before. Unskip ARM32 object file tests in goobj, nm, and objdump. Updates #19811. Change-Id: Ia46c2b68df5f1c5204d6509ceab6416ad6372315 Reviewed-on: https://go-review.googlesource.com/69010 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
2017-10-02cmd/objdump: fix and re-enable arm testAlberto Donizetti
Fixes #9021 Change-Id: Id4465857c765342aa8c4b5bc2fdc06754a290025 Reviewed-on: https://go-review.googlesource.com/67530 Reviewed-by: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
2017-08-28cmd/internal/objfile: add arm64 disassembler supportWei Xiao
Fixes #19157 Change-Id: Ieea286e8dc03929c3645f3113c33df569f8e26f3 Reviewed-on: https://go-review.googlesource.com/58930 Reviewed-by: Cherry Zhang <cherryyz@google.com>
2017-05-16cmd/internal/objabi: fix the bug of shrinking SymType down to a uint8Wei Xiao
Previous CL (cmd/internal/objabi: shrink SymType down to a uint8) shrinks SymType down to a uint8 but forgot making according change in goobj. Fixes #20296 Also add a test to catch such Goobj format inconsistency bug Change-Id: Ib43dd7122cfcacf611a643814e95f8c5a924941f Reviewed-on: https://go-review.googlesource.com/42971 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Michael Hudson-Doyle <michael.hudson@canonical.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>
2017-04-23cmd/objdump: remove two unused typesDamien Lespiau
The last mention of those types in this package are in: commit 6bd0d0542ee15fda0da545c16af43fcfd34d6334 Author: Russ Cox <rsc@golang.org> Date: Thu Nov 6 19:56:55 2014 -0500 cmd/objdump, cmd/pprof: factor disassembly into cmd/internal/objfile Found with honnef.co/go/tools/cmd/unused. Change-Id: Iacc2902f7d0784ac0efdd92da239f3e97491469a Reviewed-on: https://go-review.googlesource.com/41472 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2017-04-05cmd/objdump: print Go code alongside assemblyLorenzo Masini
Added -S flag to print go source file line above corresponding disassembly: $ go tool objdump -S -s main.main fmthello TEXT main.main(SB) /home/rugginoso/Documents/src/go/src/cmd/objdump/testdata/fmthello.go func main() { 0x47d450 64488b0c25f8ffffff FS MOVQ FS:0xfffffff8, CX 0x47d459 483b6110 CMPQ 0x10(CX), SP 0x47d45d 7631 JBE 0x47d490 0x47d45f 4883ec18 SUBQ $0x18, SP 0x47d463 48896c2410 MOVQ BP, 0x10(SP) 0x47d468 488d6c2410 LEAQ 0x10(SP), BP Println("hello, world") 0x47d46d 488d0563b00200 LEAQ 0x2b063(IP), AX 0x47d474 48890424 MOVQ AX, 0(SP) 0x47d478 48c74424080c000000 MOVQ $0xc, 0x8(SP) 0x47d481 e81a000000 CALL main.Println(SB) } 0x47d486 488b6c2410 MOVQ 0x10(SP), BP 0x47d48b 4883c418 ADDQ $0x18, SP 0x47d48f c3 RET func main() { 0x47d490 e8ebf1fcff CALL runtime.morestack_noctxt(SB) 0x47d495 ebb9 JMP main.main(SB) Execution time: $ time go tool objdump testdata/fmthello > /dev/null real 0m0.430s user 0m0.440s sys 0m0.000s $ time go tool objdump -S testdata/fmthello > /dev/null real 0m0.471s user 0m0.476s sys 0m0.012s Fixes #18245 Change-Id: I9b2f8338f9ee443c1352efd270d3ba85e3dd9b78 Reviewed-on: https://go-review.googlesource.com/37953 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
2017-02-19cmd/objdump: make test independent of inliningDavid Lazar
Fixes #19189. Change-Id: Ice69216c7fc2eaeb3dbbdcd08a8284204c7f52ef Reviewed-on: https://go-review.googlesource.com/37237 Run-TryBot: David Lazar <lazard@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
2016-12-15cmd/objdump: disable objdump_test with external linking on GOARCH=mips{,le}Vladimir Stefanovic
Updates #12559. Change-Id: I5e8f4cf7071d0d71618527a6b6096e771d5eeb28 Reviewed-on: https://go-review.googlesource.com/34317 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-11-16all: call flag.Parse from TestMain only if usedDaniel Martí
These don't use any flags in TestMain itself, so the call is redundant as M.Run will do it. Change-Id: I00f2ac7f846dc2c3ad3535eb8177616b2d900149 Reviewed-on: https://go-review.googlesource.com/33275 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-11-04cmd/objdump: speed up testsJosh Bleecher Snyder
Rebuild cmd/objdump once instead of twice. Speeds up standalone 'go test cmd/objdump' on my machine from ~1.4s to ~1s. Updates #17751 Change-Id: I15fd79cf18c310f892bc28a9e9ca47ee010c989a Reviewed-on: https://go-review.googlesource.com/32673 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2016-10-27cmd/objdump: skip tests for GOARCH=mips{,le}Vladimir Stefanovic
Change-Id: I8111ceb6960364166aa8a445f4d6d8b0581d371e Reviewed-on: https://go-review.googlesource.com/31513 Reviewed-by: Cherry Zhang <cherryyz@google.com>
2016-10-25cmd/objdump: updates from golang.org/x/arch/ppc64/ppc64asmLynn Boger
Update the ppc64x disassembly code for use by objdump from golang.org/x/arch/ppc64/ppc64asm commit fcea5ea. Enable the objdump testcase for external linking on ppc64le make a minor fix to the expected output. Fixes #17447 Change-Id: I769cc7f8bfade594690a476dfe77ab33677ac03b Reviewed-on: https://go-review.googlesource.com/32015 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2016-10-13cmd/objdump: enable tests on ppc64/ppc64leShenghou Ma
Fixes #9039. Change-Id: I7d213b4f8e4cda73ea7687fb97dbd22e58163949 Reviewed-on: https://go-review.googlesource.com/9683 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
2016-08-30all: use testing.GoToolPath instead of "go"Keith Randall
This change makes sure that tests are run with the correct version of the go tool. The correct version is the one that we invoked with "go test", not the one that is first in our path. Fixes #16577 Change-Id: If22c8f8c3ec9e7c35d094362873819f2fbb8559b Reviewed-on: https://go-review.googlesource.com/28089 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-04-12cmd/objdump: skip TestDisasm* on s390xMichael Munday
The disassembler is not yet implemented on s390x. Updates #15255. Change-Id: Ibab319c8c087b1a619baa1529398305c1e721877 Reviewed-on: https://go-review.googlesource.com/21894 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-09-10cmd/objdump: skip TestDisasm* for mips64{,le}Yao Zhang
Disassembler for mips64 is not supported yet. Change-Id: Ie923dd1e37fed47fc395b9d1cd9194e55020bee5 Reviewed-on: https://go-review.googlesource.com/14459 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-07-31cmd/objdump: don't run TestDisasmExtld if cgo is not enabledIan Lance Taylor
The test uses external linking mode, which is probably not available if cgo does not work. Fixes #11969. Change-Id: Id1c2828cd2540391e16b422bf51674ba6ff084b0 Reviewed-on: https://go-review.googlesource.com/13005 Reviewed-by: Russ Cox <rsc@golang.org>
2015-06-16all: extract "can I exec?" check from tests into internal/testenvRuss Cox
Change-Id: I7b54be9d8b50b39e01c6be21f310ae9a10404e9d Reviewed-on: https://go-review.googlesource.com/10753 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: David Crawshaw <crawshaw@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2015-06-11all: fix misprints in commentsAinar Garipov
These were found by grepping the comments from the go code and feeding the output to aspell. Change-Id: Id734d6c8d1938ec3c36bd94a4dbbad577e3ad395 Reviewed-on: https://go-review.googlesource.com/10941 Reviewed-by: Aamir Khan <syst3m.w0rm@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-04-29cmd/objdump: disable external linking test on openbsd/armJoel Sing
Disable disassembly with external linking test on openbsd/arm, since this platform does not currently support cgo/external linking. Change-Id: I6eab6fcaac21407ce05075a4a1407fbfe0e6142b Reviewed-on: https://go-review.googlesource.com/9481 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-04-13cmd/objdump: skip fork test on darwin/arm64David Crawshaw
Just like darwin/arm. Change-Id: Ibaba67980db6e05aa71568199b2dac2fcaa86fd6 Reviewed-on: https://go-review.googlesource.com/8824 Reviewed-by: Minux Ma <minux@golang.org>
2015-03-16cmd/objdump: disable TestDisasm.* on arm64Aram Hăvărneanu
ARM64 doesn't have disassembler yet. Change-Id: I016fa013b5ff50dc49d38ade42351b79be023d80 Reviewed-on: https://go-review.googlesource.com/7149 Reviewed-by: Minux Ma <minux@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
2015-02-27cmd/objdump: skip fork test on darwin/armDavid Crawshaw
Change-Id: I1d1eb71014381452d1ef368431cb2556245a35ab Reviewed-on: https://go-review.googlesource.com/6250 Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>