aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/go/gofrontend/MERGE2
-rw-r--r--gcc/go/gofrontend/escape.cc4
-rw-r--r--gcc/go/gofrontend/expressions.cc5
-rw-r--r--gcc/go/gofrontend/runtime.def3
4 files changed, 11 insertions, 3 deletions
diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE
index e7b959f..93e7215 100644
--- a/gcc/go/gofrontend/MERGE
+++ b/gcc/go/gofrontend/MERGE
@@ -1,4 +1,4 @@
-1072286ca9249bd6f75628aead325a66286bcf5b
+925635f067d40d30acf565b620cc859ee7cbc990
The first line of this file holds the git revision number of the last
merge done from the gofrontend repository.
diff --git a/gcc/go/gofrontend/escape.cc b/gcc/go/gofrontend/escape.cc
index 7bab3cb..4f95945 100644
--- a/gcc/go/gofrontend/escape.cc
+++ b/gcc/go/gofrontend/escape.cc
@@ -360,6 +360,7 @@ Node::op_format() const
break;
case Runtime::MAKECHAN:
+ case Runtime::MAKECHAN64:
case Runtime::MAKEMAP:
case Runtime::MAKESLICE:
case Runtime::MAKESLICE64:
@@ -1602,6 +1603,7 @@ Escape_analysis_assign::expression(Expression** pexpr)
switch (fe->runtime_code())
{
case Runtime::MAKECHAN:
+ case Runtime::MAKECHAN64:
case Runtime::MAKEMAP:
case Runtime::MAKESLICE:
case Runtime::MAKESLICE64:
@@ -2284,6 +2286,7 @@ Escape_analysis_assign::assign(Node* dst, Node* src)
switch (fe->runtime_code())
{
case Runtime::MAKECHAN:
+ case Runtime::MAKECHAN64:
case Runtime::MAKEMAP:
case Runtime::MAKESLICE:
case Runtime::MAKESLICE64:
@@ -3056,6 +3059,7 @@ Escape_analysis_flood::flood(Level level, Node* dst, Node* src,
switch (call->fn()->func_expression()->runtime_code())
{
case Runtime::MAKECHAN:
+ case Runtime::MAKECHAN64:
case Runtime::MAKEMAP:
case Runtime::MAKESLICE:
case Runtime::MAKESLICE64:
diff --git a/gcc/go/gofrontend/expressions.cc b/gcc/go/gofrontend/expressions.cc
index 99fb1b5..47be82f 100644
--- a/gcc/go/gofrontend/expressions.cc
+++ b/gcc/go/gofrontend/expressions.cc
@@ -7565,7 +7565,10 @@ Builtin_call_expression::lower_make(Statement_inserter* inserter)
else if (is_chan)
{
Expression* type_arg = Expression::make_type_descriptor(type, type_loc);
- call = Runtime::make_call(Runtime::MAKECHAN, loc, 2, type_arg, len_arg);
+ Runtime::Function code = Runtime::MAKECHAN;
+ if (!len_small)
+ code = Runtime::MAKECHAN64;
+ call = Runtime::make_call(code, loc, 2, type_arg, len_arg);
}
else
go_unreachable();
diff --git a/gcc/go/gofrontend/runtime.def b/gcc/go/gofrontend/runtime.def
index 605bcff..fdb159e 100644
--- a/gcc/go/gofrontend/runtime.def
+++ b/gcc/go/gofrontend/runtime.def
@@ -139,7 +139,8 @@ DEF_GO_RUNTIME(MAPITERNEXT, "runtime.mapiternext", P1(POINTER), R0())
// Make a channel.
-DEF_GO_RUNTIME(MAKECHAN, "runtime.makechan", P2(TYPE, INT64), R1(CHAN))
+DEF_GO_RUNTIME(MAKECHAN, "runtime.makechan", P2(TYPE, INT), R1(CHAN))
+DEF_GO_RUNTIME(MAKECHAN64, "runtime.makechan64", P2(TYPE, INT64), R1(CHAN))
// Send a value on a channel.
DEF_GO_RUNTIME(CHANSEND, "runtime.chansend1", P2(CHAN, POINTER), R0())