Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
Fixes golang/go#51237
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/415994
|
|
This test only needs to be compiled, not linked.
|
|
2022-03-29 Chenghua Xu <xuchenghua@loongson.cn>
Lulu Cheng <chenglulu@loongson.cn>
gcc/testsuite/ChangeLog:
* g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch.
* g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support.
* g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch.
* gcc.dg/20020312-2.c: Add LoongArch support.
* c-c++-common/zero-scratch-regs-10.c: Like wise
* c-c++-common/zero-scratch-regs-11.c: Like wise
* c-c++-common/zero-scratch-regs-8.c: Like wise
* c-c++-common/zero-scratch-regs-9.c: Like wise
* gcc.dg/loop-8.c: Skip on LoongArch.
* gcc.dg/torture/stackalign/builtin-apply-2.c: Likewise.
* gcc.dg/tree-ssa/ssa-fre-3.c: Likewise.
* go.test/go-test.exp: Define the LoongArch target.
* lib/target-supports.exp: Like wise.
* gcc.target/loongarch/loongarch.exp: New file.
* gcc.target/loongarch/tst-asm-const.c: Like wise.
* gcc.target/loongarch/larch-builtin.c: Like wise.
|
|
For golang/go#33232
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/382248
|
|
|
|
Panic if the slice is too short.
For golang/go#395
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/338630
|
|
For golang/go#19367
For golang/go#40481
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/338949
|
|
Since they are already skipped on other 32-bit architectures.
gcc/testsuite/
* go.test/test/fixedbugs/issue6036.go: Skip on sparc.
* go.test/test/fixedbugs/issue22200b.go: Likewise.
|
|
|
|
|
|
Adjust mksysinfo and mkrsysinfo to strip out floating-point max numbers,
as they can trigger this error.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/278476
|
|
Update the Go testsuite driver to handle +build lines as is done in
the upstream repo, and update some tests to the upstream repo copy
using +build lines with "gc" and "!gccgo" as appropriate.
* go.test/go-test.exp (go-set-goos): New procedure.
(go-gc-match): New procedure.
(go-gc-tests): Call go-set-goos. Use go-gc-match to handle +build
lines. Look for +build lines beyond first line of file.
|
|
|
|
|
|
|
|
This matches changes in 788d204885c187d5604e3960d7c78e1523f04861.
|
|
* go.test/go-test.exp (errchk): Retain any characters at the end
of the comment.
|
|
* go.test/go-test.exp (go-gc-tests): Recognize errorcheckdir -n,
for bug345.go.
|
|
* go.test/go-test.exp (errchk): Rewrite regexp quoting to use
curly braces, making it much simpler.
|
|
* go.test/go-test.exp (errchk): Don't backslash quote parentheses
that are already backslash quoted.
|
|
|
|
|
|
* go.test/go-test.exp (go-gc-tests): Add -I. when building all
sources in a directory (errorcheckdir, compiledir, rundir,
rundircmpout).
|
|
This updates a bunch of existing Go tests to the contents of the
source repo. This does not add any of the newer tests.
|
|
Go used to use slightly different semantics than C99 for complex division,
so we used runtime routines to handle the different. The gc compiler
has changes its behavior to match C99, so changes ours as well.
For golang/go#14644
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/274213
|
|
This should have been part of c7932d5626a81a35686a3992b5a02570aba5cd0b,
but I forgot.
|
|
This is a gofrontend copy of https://golang.org/cl/203282.
From the CL 203282 description:
"declared and not used" is technically correct, but might confuse
the user. Switching "and" to "but" will hopefully create the
contrast for the users: they did one thing (declaration), but
not the other --- actually using the variable.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273629
|
|
Use the same error as the current gc compiler.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273628
|
|
* go.test/go-test.exp (errchk): Permit trailing */ on ERROR line.
|
|
For golang/go#17328
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273890
|
|
For golang/go#14844
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273889
|
|
For golang/go#10700
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273886
|
|
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273867
|
|
Mark bad types as erroneous, to avoid generating further errors.
This required some code using array types to check for errors.
For https://golang.org/issue/19880
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/273626
|
|
|
|
This lets the test pass on AIX.
Not updating to master because we get slightly different error messages,
so that is a more complex change.
|
|
This is a language change for Go 1.14.
Updates golang/go#6977
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/214240
From-SVN: r280109
|
|
From-SVN: r279813
|
|
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/193497
From-SVN: r275473
|
|
Shifting by signed types is a new language feature in Go 1.13.
This requires a patch to the testsuite.
Updates golang/go#19113
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/190977
* go.test/test/fixedbugs/bug073.go: Update for language changes.
From-SVN: r274755
|
|
GCC recently introduced -Wformat-diag to scrutinize GCC error messages.
It reports a number of warnings about gofrontend code, such as:
../../trunk/gcc/go/gofrontend/import.cc: In member function ‘Type* Import::type_for_index(int, const string&, size_t, bool*)’:
../../trunk/gcc/go/gofrontend/import.cc:1129:48: warning: unquoted operator ‘>=’ in format [-Wformat-diag]
1129 | "error in %s at %lu: bad type index %d >= %d",
| ^~
../../trunk/gcc/go/gofrontend/ast-dump.cc: In member function ‘void Ast_dump_context::dump(Gogo*, const char*)’:
../../trunk/gcc/go/gofrontend/ast-dump.cc:203:25: warning: unquoted option name ‘-fgo-dump-ast’ in format [-Wformat-diag]
203 | "cannot open %s:%m, -fgo-dump-ast ignored", dumpname.c_str());
| ^~~~~~~~~~~~~
../../trunk/gcc/go/gofrontend/expressions.cc: In static member function ‘static Bexpression* Func_expression::get_code_pointer(Gogo*, Named_object*, Location)’:
../../trunk/gcc/go/gofrontend/expressions.cc:1350:29: warning: misspelled term ‘builtin function’ in format; use ‘built-in function’ instead [-Wformat-diag]
1350 | "invalid use of special builtin function %qs; must be called",
| ^~~~~~~~~~~~~~~~
../../trunk/gcc/go/gofrontend/gogo.cc: In member function ‘void Gogo::add_linkname(const string&, bool, const string&, Location)’:
../../trunk/gcc/go/gofrontend/gogo.cc:2527:4: warning: unquoted sequence of 2 consecutive punctuation characters ‘//’ in format [-Wformat-diag]
2527 | ("%s is not a function; "
| ~^~~~~~~~~~~~~~~~~~~~~~~~
2528 | "//go:linkname is only supported for functions"),
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This CL edits error messages to avoid these warnings.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/183497
* go.test/test/blank1.go: Update for diagnostic message changes.
From-SVN: r272608
|
|
If an interface does not escape, it doesn't need a heap
allocation to hold the data (for non-direct interface type).
This CL improves the escape analysis to track interface
conversions, and reduces these allocations.
Implicit interface conversions were mostly added late in the
compilation pipeline, after the escape analysis. For the escape
analysis to see them, we move the introduction of these
conversions earlier, right before the escape analysis.
Now that the compiler can generate interface conversions inlined,
gcc/testsuite/go.test/test/nilptr2.go needs to be adjusted as in
golang.org/cl/176579, so the use function does an actual use.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/176459
* go.test/test/nilptr2.go: Change use function to actually do
something.
From-SVN: r271276
|
|
From-SVN: r267494
|
|
From-SVN: r264825
|
|
Reviewed-on: https://go-review.googlesource.com/136435
gotools/:
* Makefile.am (mostlyclean-local): Run chmod on check-go-dir to
make sure it is writable.
(check-go-tools): Likewise.
(check-vet): Copy internal/objabi to check-vet-dir.
* Makefile.in: Rebuild.
From-SVN: r264546
|
|
PR go/84484
libgo: add support for riscv64
Patch by Andreas Schwab.
Reviewed-on: https://go-review.googlesource.com/96377
* go.test/go-test.exp (go-set-goarch): Recognize riscv64-*-*.
From-SVN: r257914
|
|
From-SVN: r256169
|
|
Reviewed-on: https://go-review.googlesource.com/63753
From-SVN: r252767
|
|
* go.test/go-test.exp (go-set-goarch): Update MIPS architecture
names.
From-SVN: r249589
|