406 virtual int Opcode() const; |
406 virtual int Opcode() const; |
407 const Type *bottom_type() const { return Type::DOUBLE; } |
407 const Type *bottom_type() const { return Type::DOUBLE; } |
408 virtual uint ideal_reg() const { return Op_RegD; } |
408 virtual uint ideal_reg() const { return Op_RegD; } |
409 }; |
409 }; |
410 |
410 |
411 //------------------------------CosDNode--------------------------------------- |
411 //------------------------------TanDNode--------------------------------------- |
412 // Cosinus of a double |
412 // tangens of a double |
413 class CosDNode : public Node { |
413 class TanDNode : public Node { |
414 public: |
414 public: |
415 CosDNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
415 TanDNode(Compile* C, Node *c,Node *in1) : Node(c, in1) { |
416 init_flags(Flag_is_expensive); |
416 init_flags(Flag_is_expensive); |
417 C->add_expensive_node(this); |
417 C->add_expensive_node(this); |
418 } |
418 } |
419 virtual int Opcode() const; |
419 virtual int Opcode() const; |
420 const Type *bottom_type() const { return Type::DOUBLE; } |
420 const Type *bottom_type() const { return Type::DOUBLE; } |
421 virtual uint ideal_reg() const { return Op_RegD; } |
421 virtual uint ideal_reg() const { return Op_RegD; } |
422 virtual const Type *Value( PhaseTransform *phase ) const; |
422 virtual const Type *Value( PhaseTransform *phase ) const; |
423 }; |
423 }; |
424 |
424 |
425 //------------------------------CosDNode--------------------------------------- |
425 |
426 // Sinus of a double |
426 //------------------------------AtanDNode-------------------------------------- |
427 class SinDNode : public Node { |
427 // arcus tangens of a double |
428 public: |
428 class AtanDNode : public Node { |
429 SinDNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
429 public: |
|
430 AtanDNode(Node *c, Node *in1, Node *in2 ) : Node(c, in1, in2) {} |
|
431 virtual int Opcode() const; |
|
432 const Type *bottom_type() const { return Type::DOUBLE; } |
|
433 virtual uint ideal_reg() const { return Op_RegD; } |
|
434 }; |
|
435 |
|
436 |
|
437 //------------------------------SqrtDNode-------------------------------------- |
|
438 // square root a double |
|
439 class SqrtDNode : public Node { |
|
440 public: |
|
441 SqrtDNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
430 init_flags(Flag_is_expensive); |
442 init_flags(Flag_is_expensive); |
431 C->add_expensive_node(this); |
443 C->add_expensive_node(this); |
432 } |
444 } |
433 virtual int Opcode() const; |
445 virtual int Opcode() const; |
434 const Type *bottom_type() const { return Type::DOUBLE; } |
446 const Type *bottom_type() const { return Type::DOUBLE; } |
435 virtual uint ideal_reg() const { return Op_RegD; } |
447 virtual uint ideal_reg() const { return Op_RegD; } |
436 virtual const Type *Value( PhaseTransform *phase ) const; |
448 virtual const Type *Value( PhaseTransform *phase ) const; |
437 }; |
449 }; |
438 |
450 |
439 |
451 //------------------------------Log10DNode--------------------------------------- |
440 //------------------------------TanDNode--------------------------------------- |
452 // Log_10 of a double |
441 // tangens of a double |
453 class Log10DNode : public Node { |
442 class TanDNode : public Node { |
454 public: |
443 public: |
455 Log10DNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
444 TanDNode(Compile* C, Node *c,Node *in1) : Node(c, in1) { |
|
445 init_flags(Flag_is_expensive); |
456 init_flags(Flag_is_expensive); |
446 C->add_expensive_node(this); |
457 C->add_expensive_node(this); |
447 } |
458 } |
448 virtual int Opcode() const; |
459 virtual int Opcode() const; |
449 const Type *bottom_type() const { return Type::DOUBLE; } |
460 const Type *bottom_type() const { return Type::DOUBLE; } |
450 virtual uint ideal_reg() const { return Op_RegD; } |
461 virtual uint ideal_reg() const { return Op_RegD; } |
451 virtual const Type *Value( PhaseTransform *phase ) const; |
462 virtual const Type *Value( PhaseTransform *phase ) const; |
452 }; |
463 }; |
453 |
464 |
454 |
|
455 //------------------------------AtanDNode-------------------------------------- |
|
456 // arcus tangens of a double |
|
457 class AtanDNode : public Node { |
|
458 public: |
|
459 AtanDNode(Node *c, Node *in1, Node *in2 ) : Node(c, in1, in2) {} |
|
460 virtual int Opcode() const; |
|
461 const Type *bottom_type() const { return Type::DOUBLE; } |
|
462 virtual uint ideal_reg() const { return Op_RegD; } |
|
463 }; |
|
464 |
|
465 |
|
466 //------------------------------SqrtDNode-------------------------------------- |
|
467 // square root a double |
|
468 class SqrtDNode : public Node { |
|
469 public: |
|
470 SqrtDNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
|
471 init_flags(Flag_is_expensive); |
|
472 C->add_expensive_node(this); |
|
473 } |
|
474 virtual int Opcode() const; |
|
475 const Type *bottom_type() const { return Type::DOUBLE; } |
|
476 virtual uint ideal_reg() const { return Op_RegD; } |
|
477 virtual const Type *Value( PhaseTransform *phase ) const; |
|
478 }; |
|
479 |
|
480 //------------------------------Log10DNode--------------------------------------- |
|
481 // Log_10 of a double |
|
482 class Log10DNode : public Node { |
|
483 public: |
|
484 Log10DNode(Compile* C, Node *c, Node *in1) : Node(c, in1) { |
|
485 init_flags(Flag_is_expensive); |
|
486 C->add_expensive_node(this); |
|
487 } |
|
488 virtual int Opcode() const; |
|
489 const Type *bottom_type() const { return Type::DOUBLE; } |
|
490 virtual uint ideal_reg() const { return Op_RegD; } |
|
491 virtual const Type *Value( PhaseTransform *phase ) const; |
|
492 }; |
|
493 |
|
494 //-------------------------------ReverseBytesINode-------------------------------- |
465 //-------------------------------ReverseBytesINode-------------------------------- |
495 // reverse bytes of an integer |
466 // reverse bytes of an integer |
496 class ReverseBytesINode : public Node { |
467 class ReverseBytesINode : public Node { |
497 public: |
468 public: |
498 ReverseBytesINode(Node *c, Node *in1) : Node(c, in1) {} |
469 ReverseBytesINode(Node *c, Node *in1) : Node(c, in1) {} |