Deleted Added
sdiff udiff text old ( 13633:985e9c018cbf ) new ( 13653:079472978bca )
full compact
1// -*- mode:c++ -*-
2
3// Copyright (c) 2015 RISC-V Foundation
4// Copyright (c) 2017 The University of Virginia
5// All rights reserved.
6//
7// Redistribution and use in source and binary forms, with or without
8// modification, are permitted provided that the following conditions are

--- 498 unchanged lines hidden (view full) ---

507 0x2: LoadReserved::lr_w({{
508 Rd_sd = Mem_sw;
509 }}, mem_flags=LLSC);
510 0x3: StoreCond::sc_w({{
511 Mem_uw = Rs2_uw;
512 }}, {{
513 Rd = result;
514 }}, inst_flags=IsStoreConditional, mem_flags=LLSC);
515 format AtomicMemOp {
516 0x0: amoadd_w({{Rt_sd = Mem_sw;}}, {{
517 Mem_sw = Rs2_sw + Rt_sd;
518 Rd_sd = Rt_sd;
519 }}, {{EA = Rs1;}});
520 0x1: amoswap_w({{Rt_sd = Mem_sw;}}, {{
521 Mem_sw = Rs2_uw;
522 Rd_sd = Rt_sd;
523 }}, {{EA = Rs1;}});
524 0x4: amoxor_w({{Rt_sd = Mem_sw;}}, {{
525 Mem_sw = Rs2_uw^Rt_sd;
526 Rd_sd = Rt_sd;
527 }}, {{EA = Rs1;}});
528 0x8: amoor_w({{Rt_sd = Mem_sw;}}, {{
529 Mem_sw = Rs2_uw | Rt_sd;
530 Rd_sd = Rt_sd;
531 }}, {{EA = Rs1;}});
532 0xc: amoand_w({{Rt_sd = Mem_sw;}}, {{
533 Mem_sw = Rs2_uw&Rt_sd;
534 Rd_sd = Rt_sd;
535 }}, {{EA = Rs1;}});
536 0x10: amomin_w({{Rt_sd = Mem_sw;}}, {{
537 Mem_sw = min<int32_t>(Rs2_sw, Rt_sd);
538 Rd_sd = Rt_sd;
539 }}, {{EA = Rs1;}});
540 0x14: amomax_w({{Rt_sd = Mem_sw;}}, {{
541 Mem_sw = max<int32_t>(Rs2_sw, Rt_sd);
542 Rd_sd = Rt_sd;
543 }}, {{EA = Rs1;}});
544 0x18: amominu_w({{Rt_sd = Mem_sw;}}, {{
545 Mem_sw = min<uint32_t>(Rs2_uw, Rt_sd);
546 Rd_sd = Rt_sd;
547 }}, {{EA = Rs1;}});
548 0x1c: amomaxu_w({{Rt_sd = Mem_sw;}}, {{
549 Mem_sw = max<uint32_t>(Rs2_uw, Rt_sd);
550 Rd_sd = Rt_sd;
551 }}, {{EA = Rs1;}});
552 }
553 }
554 0x3: decode AMOFUNCT {
555 0x2: LoadReserved::lr_d({{
556 Rd_sd = Mem_sd;
557 }}, mem_flags=LLSC);
558 0x3: StoreCond::sc_d({{
559 Mem = Rs2;
560 }}, {{
561 Rd = result;
562 }}, mem_flags=LLSC, inst_flags=IsStoreConditional);
563 format AtomicMemOp {
564 0x0: amoadd_d({{Rt_sd = Mem_sd;}}, {{
565 Mem_sd = Rs2_sd + Rt_sd;
566 Rd_sd = Rt_sd;
567 }}, {{EA = Rs1;}});
568 0x1: amoswap_d({{Rt = Mem;}}, {{
569 Mem = Rs2;
570 Rd = Rt;
571 }}, {{EA = Rs1;}});
572 0x4: amoxor_d({{Rt = Mem;}}, {{
573 Mem = Rs2^Rt;
574 Rd = Rt;
575 }}, {{EA = Rs1;}});
576 0x8: amoor_d({{Rt = Mem;}}, {{
577 Mem = Rs2 | Rt;
578 Rd = Rt;
579 }}, {{EA = Rs1;}});
580 0xc: amoand_d({{Rt = Mem;}}, {{
581 Mem = Rs2&Rt;
582 Rd = Rt;
583 }}, {{EA = Rs1;}});
584 0x10: amomin_d({{Rt_sd = Mem_sd;}}, {{
585 Mem_sd = min(Rs2_sd, Rt_sd);
586 Rd_sd = Rt_sd;
587 }}, {{EA = Rs1;}});
588 0x14: amomax_d({{Rt_sd = Mem_sd;}}, {{
589 Mem_sd = max(Rs2_sd, Rt_sd);
590 Rd_sd = Rt_sd;
591 }}, {{EA = Rs1;}});
592 0x18: amominu_d({{Rt = Mem;}}, {{
593 Mem = min(Rs2, Rt);
594 Rd = Rt;
595 }}, {{EA = Rs1;}});
596 0x1c: amomaxu_d({{Rt = Mem;}}, {{
597 Mem = max(Rs2, Rt);
598 Rd = Rt;
599 }}, {{EA = Rs1;}});
600 }
601 }
602 }
603 0x0c: decode FUNCT3 {
604 format ROp {
605 0x0: decode FUNCT7 {
606 0x0: add({{
607 Rd = Rs1_sd + Rs2_sd;
608 }});

--- 1177 unchanged lines hidden ---