Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.graal.api.code/src/com/oracle/graal/api/code/CompilationResult.java @ 19251:063e8873bd14
changed type of assumptions field in CompilationResult from Assumptions to Assumption[]
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Wed, 11 Feb 2015 11:38:22 +0100 |
parents | 7ebed83df427 |
children | 131fb3dd493b |
comparison
equal
deleted
inserted
replaced
19250:8ab925a6f724 | 19251:063e8873bd14 |
---|---|
26 import static java.util.Collections.*; | 26 import static java.util.Collections.*; |
27 | 27 |
28 import java.io.*; | 28 import java.io.*; |
29 import java.util.*; | 29 import java.util.*; |
30 | 30 |
31 import com.oracle.graal.api.code.Assumptions.Assumption; | |
31 import com.oracle.graal.api.code.CodeUtil.RefMapFormatter; | 32 import com.oracle.graal.api.code.CodeUtil.RefMapFormatter; |
32 import com.oracle.graal.api.meta.*; | 33 import com.oracle.graal.api.meta.*; |
33 | 34 |
34 /** | 35 /** |
35 * Represents the output from compiling a method, including the compiled machine code, associated | 36 * Represents the output from compiling a method, including the compiled machine code, associated |
526 */ | 527 */ |
527 private int targetCodeSize; | 528 private int targetCodeSize; |
528 | 529 |
529 private ArrayList<CodeAnnotation> annotations; | 530 private ArrayList<CodeAnnotation> annotations; |
530 | 531 |
531 private Assumptions assumptions; | 532 private Assumption[] assumptions; |
532 | 533 |
533 public CompilationResult() { | 534 public CompilationResult() { |
534 this(null); | 535 this(null); |
535 } | 536 } |
536 | 537 |
605 public void setEntryBCI(int entryBCI) { | 606 public void setEntryBCI(int entryBCI) { |
606 this.entryBCI = entryBCI; | 607 this.entryBCI = entryBCI; |
607 } | 608 } |
608 | 609 |
609 public void setAssumptions(Assumptions assumptions) { | 610 public void setAssumptions(Assumptions assumptions) { |
610 this.assumptions = assumptions; | 611 this.assumptions = assumptions.getAssumptionsCopy(); |
611 } | 612 } |
612 | 613 |
613 public Assumptions getAssumptions() { | 614 /** |
614 return assumptions; | 615 * Gets a fixed-size {@linkplain Arrays#asList(Object...) view} of the assumptions recorded in |
616 * this object. | |
617 */ | |
618 public Collection<Assumption> getAssumptions() { | |
619 return assumptions == null ? Collections.emptyList() : Arrays.asList(assumptions); | |
615 } | 620 } |
616 | 621 |
617 public DataSection getDataSection() { | 622 public DataSection getDataSection() { |
618 return dataSection; | 623 return dataSection; |
619 } | 624 } |