395 };
396
397 class RangeCheckNode : public IfNode {
398 private:
399 int is_range_check(Node* &range, Node* &index, jint &offset);
400
401 public:
402 RangeCheckNode(Node* control, Node *b, float p, float fcnt)
403 : IfNode(control, b, p, fcnt) {
404 init_class_id(Class_RangeCheck);
405 }
406
407 virtual int Opcode() const;
408 virtual Node* Ideal(PhaseGVN *phase, bool can_reshape);
409 };
410
411 class IfProjNode : public CProjNode {
412 public:
413 IfProjNode(IfNode *ifnode, uint idx) : CProjNode(ifnode,idx) {}
414 virtual Node *Identity(PhaseTransform *phase);
415
416 protected:
417 // Type of If input when this branch is always taken
418 virtual bool always_taken(const TypeTuple* t) const = 0;
419
420 #ifndef PRODUCT
421 public:
422 virtual void related(GrowableArray<Node*> *in_rel, GrowableArray<Node*> *out_rel, bool compact) const;
423 #endif
424 };
425
426 class IfTrueNode : public IfProjNode {
427 public:
428 IfTrueNode( IfNode *ifnode ) : IfProjNode(ifnode,1) {
429 init_class_id(Class_IfTrue);
430 }
431 virtual int Opcode() const;
432
433 protected:
434 virtual bool always_taken(const TypeTuple* t) const { return t == TypeTuple::IFTRUE; }
|
395 };
396
397 class RangeCheckNode : public IfNode {
398 private:
399 int is_range_check(Node* &range, Node* &index, jint &offset);
400
401 public:
402 RangeCheckNode(Node* control, Node *b, float p, float fcnt)
403 : IfNode(control, b, p, fcnt) {
404 init_class_id(Class_RangeCheck);
405 }
406
407 virtual int Opcode() const;
408 virtual Node* Ideal(PhaseGVN *phase, bool can_reshape);
409 };
410
411 class IfProjNode : public CProjNode {
412 public:
413 IfProjNode(IfNode *ifnode, uint idx) : CProjNode(ifnode,idx) {}
414 virtual Node *Identity(PhaseTransform *phase);
415 virtual Node* Ideal(PhaseGVN* phase, bool can_reshape);
416
417 protected:
418 // Type of If input when this branch is always taken
419 virtual bool always_taken(const TypeTuple* t) const = 0;
420
421 #ifndef PRODUCT
422 public:
423 virtual void related(GrowableArray<Node*> *in_rel, GrowableArray<Node*> *out_rel, bool compact) const;
424 #endif
425 };
426
427 class IfTrueNode : public IfProjNode {
428 public:
429 IfTrueNode( IfNode *ifnode ) : IfProjNode(ifnode,1) {
430 init_class_id(Class_IfTrue);
431 }
432 virtual int Opcode() const;
433
434 protected:
435 virtual bool always_taken(const TypeTuple* t) const { return t == TypeTuple::IFTRUE; }
|