Changeset 783 for branches/RWT/modules/vci_mem_cache/caba/source/include
- Timestamp:
- Aug 29, 2014, 11:41:01 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/RWT/modules/vci_mem_cache/caba/source/include/vci_mem_cache.h
r780 r783 399 399 // b1 accÚs table llsc type SW / other 400 400 // b2 WRITE/CAS/LL/SC 401 TYPE_READ_DATA_UNC 402 TYPE_READ_DATA_MISS 403 TYPE_READ_INS_UNC 404 TYPE_READ_INS_MISS 405 TYPE_WRITE 406 TYPE_CAS 407 TYPE_LL 408 TYPE_SC 401 TYPE_READ_DATA_UNC = 0x0, 402 TYPE_READ_DATA_MISS = 0x1, 403 TYPE_READ_INS_UNC = 0x2, 404 TYPE_READ_INS_MISS = 0x3, 405 TYPE_WRITE = 0x4, 406 TYPE_CAS = 0x5, 407 TYPE_LL = 0x6, 408 TYPE_SC = 0x7 409 409 }; 410 410 … … 412 412 enum sc_status_type_e 413 413 { 414 SC_SUCCESS =0x00000000,415 SC_FAIL =0x00000001414 SC_SUCCESS = 0x00000000, 415 SC_FAIL = 0x00000001 416 416 }; 417 417 418 418 // debug variables 419 bool 420 bool 421 size_t 422 bool 423 data_t * 424 data_t * 419 bool m_debug; 420 bool m_debug_previous_valid; 421 size_t m_debug_previous_count; 422 bool m_debug_previous_dirty; 423 data_t * m_debug_previous_data; 424 data_t * m_debug_data; 425 425 426 426 // instrumentation counters 427 uint32_t m_cpt_cycles; // Counter of cycles 428 429 // Counters accessible in software (not yet but eventually) 430 uint32_t m_cpt_reset_count; // Last cycle at which counters have been reset 431 uint32_t m_cpt_read_local; // Number of local READ transactions 432 uint32_t m_cpt_read_remote; // number of remote READ transactions 433 uint32_t m_cpt_read_cost; // Number of (flits * distance) for READs 434 435 uint32_t m_cpt_write_local; // Number of local WRITE transactions 436 uint32_t m_cpt_write_remote; // number of remote WRITE transactions 437 uint32_t m_cpt_write_flits_local; // number of flits for local WRITEs 438 uint32_t m_cpt_write_flits_remote; // number of flits for remote WRITEs 439 uint32_t m_cpt_write_cost; // Number of (flits * distance) for WRITEs 440 uint32_t m_cpt_write_ncc_miss; // Number of write on ncc line 441 442 uint32_t m_cpt_ll_local; // Number of local LL transactions 443 uint32_t m_cpt_ll_remote; // number of remote LL transactions 444 uint32_t m_cpt_ll_cost; // Number of (flits * distance) for LLs 445 446 uint32_t m_cpt_sc_local; // Number of local SC transactions 447 uint32_t m_cpt_sc_remote; // number of remote SC transactions 448 uint32_t m_cpt_sc_cost; // Number of (flits * distance) for SCs 449 450 uint32_t m_cpt_cas_local; // Number of local SC transactions 451 uint32_t m_cpt_cas_remote; // number of remote SC transactions 452 uint32_t m_cpt_cas_cost; // Number of (flits * distance) for SCs 453 454 uint32_t m_cpt_update; // Number of requests causing an UPDATE 455 uint32_t m_cpt_update_local; // Number of local UPDATE transactions 456 uint32_t m_cpt_update_remote; // Number of remote UPDATE transactions 457 uint32_t m_cpt_update_cost; // Number of (flits * distance) for UPDT 458 459 uint32_t m_cpt_minval; // Number of requests causing M_INV 460 uint32_t m_cpt_minval_local; // Number of local M_INV transactions 461 uint32_t m_cpt_minval_remote; // Number of remote M_INV transactions 462 uint32_t m_cpt_minval_cost; // Number of (flits * distance) for M_INV 463 464 uint32_t m_cpt_binval; // Number of BROADCAST INVAL 465 466 uint32_t m_cpt_cleanup_local; // Number of local CLEANUP transactions 467 uint32_t m_cpt_cleanup_remote; // Number of remote CLEANUP transactions 468 uint32_t m_cpt_cleanup_cost; // Number of (flits * distance) for CLEANUPs 469 470 // Counters not accessible by software 471 uint32_t m_cpt_read_miss; // Number of MISS READ 472 uint32_t m_cpt_write_miss; // Number of MISS WRITE 473 uint32_t m_cpt_write_dirty; // Cumulated length for WRITE transactions 474 uint32_t m_cpt_write_broadcast;// Number of BROADCAST INVAL because write 475 476 uint32_t m_cpt_trt_rb; // Read blocked by a hit in trt 477 uint32_t m_cpt_trt_full; // Transaction blocked due to a full trt 427 uint32_t m_cpt_cycles; // Counter of cycles 428 429 // Counters accessible in software (not yet but eventually) and tagged 430 uint32_t m_cpt_reset_count; // Last cycle at which counters have been reset 431 uint32_t m_cpt_read_local; // Number of local READ transactions 432 uint32_t m_cpt_read_remote; // number of remote READ transactions 433 uint32_t m_cpt_read_cost; // Number of (flits * distance) for READs 434 435 uint32_t m_cpt_write_local; // Number of local WRITE transactions 436 uint32_t m_cpt_write_remote; // number of remote WRITE transactions 437 uint32_t m_cpt_write_flits_local; // number of flits for local WRITEs 438 uint32_t m_cpt_write_flits_remote; // number of flits for remote WRITEs 439 uint32_t m_cpt_write_cost; // Number of (flits * distance) for WRITEs 440 uint32_t m_cpt_write_ncc_miss; // Number of write on ncc line 441 442 uint32_t m_cpt_ll_local; // Number of local LL transactions 443 uint32_t m_cpt_ll_remote; // number of remote LL transactions 444 uint32_t m_cpt_ll_cost; // Number of (flits * distance) for LLs 445 446 uint32_t m_cpt_sc_local; // Number of local SC transactions 447 uint32_t m_cpt_sc_remote; // number of remote SC transactions 448 uint32_t m_cpt_sc_cost; // Number of (flits * distance) for SCs 449 450 uint32_t m_cpt_cas_local; // Number of local SC transactions 451 uint32_t m_cpt_cas_remote; // number of remote SC transactions 452 uint32_t m_cpt_cas_cost; // Number of (flits * distance) for SCs 453 454 uint32_t m_cpt_update; // Number of requests causing an UPDATE 455 uint32_t m_cpt_update_local; // Number of local UPDATE transactions 456 uint32_t m_cpt_update_remote; // Number of remote UPDATE transactions 457 uint32_t m_cpt_update_cost; // Number of (flits * distance) for UPDT 458 459 uint32_t m_cpt_minval; // Number of requests causing M_INV 460 uint32_t m_cpt_minval_local; // Number of local M_INV transactions 461 uint32_t m_cpt_minval_remote; // Number of remote M_INV transactions 462 uint32_t m_cpt_minval_cost; // Number of (flits * distance) for M_INV 463 464 uint32_t m_cpt_binval; // Number of BROADCAST INVAL 465 466 uint32_t m_cpt_cleanup_local; // Number of local CLEANUP transactions (all cleanup types) 467 uint32_t m_cpt_cleanup_remote; // Number of remote CLEANUP transactions (all cleanup types) 468 uint32_t m_cpt_cleanup_cost; // Number of (flits * distance) for CLEANUPs (all types) 469 470 // Counters not accessible by software, but tagged 471 uint32_t m_cpt_read_miss; // Number of MISS READ 472 uint32_t m_cpt_write_miss; // Number of MISS WRITE 473 uint32_t m_cpt_write_dirty; // Cumulated length for WRITE transactions 474 uint32_t m_cpt_write_broadcast; // Number of BROADCAST INVAL because write 475 476 uint32_t m_cpt_trt_rb; // Read blocked by a hit in trt 477 uint32_t m_cpt_trt_full; // Transaction blocked due to a full trt 478 479 uint32_t m_cpt_heap_unused; // NB cycles HEAP LOCK unused 480 uint32_t m_cpt_heap_slot_available; // NB HEAP slot available refresh at each cycles 481 uint32_t m_cpt_heap_min_slot_available; // NB HEAP : Min of slot available 482 483 uint32_t m_cpt_ncc_to_cc_read; // NB change from NCC to CC caused by a READ 484 uint32_t m_cpt_ncc_to_cc_write; // NB change from NCC to CC caused by a WRITE 485 486 uint32_t m_cpt_cleanup_data_local; // Number of local cleanups with data 487 uint32_t m_cpt_cleanup_data_remote; // Number of remote cleanups with data 488 uint32_t m_cpt_cleanup_data_cost; // Cost for cleanups with data 489 490 uint32_t m_cpt_update_flits; // Number of flits for UPDATEs 491 uint32_t m_cpt_inval_cost; // Number of (flits * distance) for INVALs 492 493 uint32_t m_cpt_get; 494 uint32_t m_cpt_put; 495 496 // TODO: clean the following counters (not necessarily useful and well-implemented) 497 uint32_t m_cpt_read_fsm_dir_lock; // wait DIR LOCK 498 uint32_t m_cpt_read_fsm_n_dir_lock; // NB DIR LOCK 499 uint32_t m_cpt_write_fsm_dir_lock; // wait DIR LOCK 500 uint32_t m_cpt_write_fsm_n_dir_lock; // NB DIR LOCK 501 uint32_t m_cpt_xram_rsp_fsm_dir_lock; // wait DIR LOCK 502 uint32_t m_cpt_xram_rsp_fsm_n_dir_lock; // NB DIR LOCK 503 uint32_t m_cpt_cas_fsm_dir_lock; // wait DIR LOCK 504 uint32_t m_cpt_cas_fsm_n_dir_lock; // NB DIR LOCK 505 uint32_t m_cpt_cleanup_fsm_dir_lock; // wait DIR LOCK 506 uint32_t m_cpt_cleanup_fsm_n_dir_lock; // NB DIR LOCK 478 507 479 uint32_t m_cpt_read_fsm_dir_lock; // wait DIR LOCK 480 uint32_t m_cpt_read_fsm_n_dir_lock; // NB DIR LOCK 481 uint32_t m_cpt_write_fsm_dir_lock; // wait DIR LOCK 482 uint32_t m_cpt_write_fsm_n_dir_lock; // NB DIR LOCK 483 uint32_t m_cpt_xram_rsp_fsm_dir_lock; // wait DIR LOCK 484 uint32_t m_cpt_xram_rsp_fsm_n_dir_lock; // NB DIR LOCK 485 uint32_t m_cpt_cas_fsm_dir_lock; // wait DIR LOCK 486 uint32_t m_cpt_cas_fsm_n_dir_lock; // NB DIR LOCK 487 uint32_t m_cpt_cleanup_fsm_dir_lock; // wait DIR LOCK 488 uint32_t m_cpt_cleanup_fsm_n_dir_lock; // NB DIR LOCK 508 uint32_t m_cpt_dir_unused; // NB cycles DIR LOCK unused 509 uint32_t m_cpt_read_fsm_dir_used; // NB cycles DIR LOCK used 510 uint32_t m_cpt_write_fsm_dir_used; // NB cycles DIR LOCK used 511 uint32_t m_cpt_cas_fsm_dir_used; // NB cycles DIR LOCK used 512 uint32_t m_cpt_xram_rsp_fsm_dir_used; // NB cycles DIR LOCK used 513 uint32_t m_cpt_cleanup_fsm_dir_used; // NB cycles DIR LOCK used 514 515 uint32_t m_cpt_read_fsm_trt_lock; // wait TRT LOCK 516 uint32_t m_cpt_write_fsm_trt_lock; // wait TRT LOCK 517 uint32_t m_cpt_cas_fsm_trt_lock; // wait TRT LOCK 518 uint32_t m_cpt_xram_rsp_fsm_trt_lock; // wait TRT LOCK 519 uint32_t m_cpt_ixr_fsm_trt_lock; // wait TRT LOCK 489 520 490 uint32_t m_cpt_dir_unused; // NB cycles DIR LOCK unused 491 uint32_t m_cpt_read_fsm_dir_used; // NB cycles DIR LOCK used 492 uint32_t m_cpt_write_fsm_dir_used; // NB cycles DIR LOCK used 493 uint32_t m_cpt_cas_fsm_dir_used; // NB cycles DIR LOCK used 494 uint32_t m_cpt_xram_rsp_fsm_dir_used; // NB cycles DIR LOCK used 495 uint32_t m_cpt_cleanup_fsm_dir_used; // NB cycles DIR LOCK used 496 497 uint32_t m_cpt_read_fsm_trt_lock; // wait TRT LOCK 498 uint32_t m_cpt_write_fsm_trt_lock; // wait TRT LOCK 499 uint32_t m_cpt_cas_fsm_trt_lock; // wait TRT LOCK 500 uint32_t m_cpt_xram_rsp_fsm_trt_lock; // wait TRT LOCK 501 uint32_t m_cpt_ixr_fsm_trt_lock; // wait TRT LOCK 521 uint32_t m_cpt_read_fsm_n_trt_lock; // NB TRT LOCK 522 uint32_t m_cpt_write_fsm_n_trt_lock; // NB TRT LOCK 523 uint32_t m_cpt_cas_fsm_n_trt_lock; // NB TRT LOCK 524 uint32_t m_cpt_xram_rsp_fsm_n_trt_lock; // NB TRT LOCK 525 uint32_t m_cpt_ixr_fsm_n_trt_lock; // NB TRT LOCK 526 527 uint32_t m_cpt_read_fsm_trt_used; // NB cycles TRT LOCK used 528 uint32_t m_cpt_write_fsm_trt_used; // NB cycles TRT LOCK used 529 uint32_t m_cpt_cas_fsm_trt_used; // NB cycles TRT LOCK used 530 uint32_t m_cpt_xram_rsp_fsm_trt_used; // NB cycles TRT LOCK used 531 uint32_t m_cpt_ixr_fsm_trt_used; // NB cycles TRT LOCK used 502 532 503 uint32_t m_cpt_read_fsm_n_trt_lock; // NB TRT LOCK 504 uint32_t m_cpt_write_fsm_n_trt_lock; // NB TRT LOCK 505 uint32_t m_cpt_cas_fsm_n_trt_lock; // NB TRT LOCK 506 uint32_t m_cpt_xram_rsp_fsm_n_trt_lock; // NB TRT LOCK 507 uint32_t m_cpt_ixr_fsm_n_trt_lock; // NB TRT LOCK 508 509 uint32_t m_cpt_read_fsm_trt_used; // NB cycles TRT LOCK used 510 uint32_t m_cpt_write_fsm_trt_used; // NB cycles TRT LOCK used 511 uint32_t m_cpt_cas_fsm_trt_used; // NB cycles TRT LOCK used 512 uint32_t m_cpt_xram_rsp_fsm_trt_used; // NB cycles TRT LOCK used 513 uint32_t m_cpt_ixr_fsm_trt_used; // NB cycles TRT LOCK used 533 uint32_t m_cpt_trt_unused; // NB cycles TRT LOCK unused 534 535 uint32_t m_cpt_write_fsm_upt_lock; // wait UPT LOCK 536 uint32_t m_cpt_xram_rsp_fsm_upt_lock; // wait UPT LOCK 537 uint32_t m_cpt_multi_ack_fsm_upt_lock; // wait UPT LOCK 538 uint32_t m_cpt_cleanup_fsm_ivt_lock; // wait UPT LOCK 539 uint32_t m_cpt_cas_fsm_upt_lock; // wait UPT LOCK 514 540 515 uint32_t m_cpt_trt_unused; // NB cycles TRT LOCK unused 516 517 uint32_t m_cpt_write_fsm_upt_lock; // wait UPT LOCK 518 uint32_t m_cpt_xram_rsp_fsm_upt_lock; // wait UPT LOCK 519 uint32_t m_cpt_multi_ack_fsm_upt_lock; // wait UPT LOCK 520 uint32_t m_cpt_cleanup_fsm_ivt_lock; // wait UPT LOCK 521 uint32_t m_cpt_cas_fsm_upt_lock; // wait UPT LOCK 541 uint32_t m_cpt_write_fsm_n_upt_lock; // NB UPT LOCK 542 uint32_t m_cpt_xram_rsp_fsm_n_upt_lock; // NB UPT LOCK 543 uint32_t m_cpt_multi_ack_fsm_n_upt_lock; // NB UPT LOCK 544 uint32_t m_cpt_cleanup_fsm_n_upt_lock; // NB UPT LOCK 545 uint32_t m_cpt_cas_fsm_n_upt_lock; // NB UPT LOCK 522 546 523 uint32_t m_cpt_write_fsm_n_upt_lock; // NB UPT LOCK524 uint32_t m_cpt_xram_rsp_fsm_n_upt_lock; // NB UPT LOCK525 uint32_t m_cpt_multi_ack_fsm_n_upt_lock; // NB UPT LOCK526 uint32_t m_cpt_cleanup_fsm_n_upt_lock; // NB UPT LOCK527 uint32_t m_cpt_cas_fsm_n_upt_lock; // NB UPT LOCK547 uint32_t m_cpt_write_fsm_upt_used; // NB cycles UPT LOCK used 548 uint32_t m_cpt_xram_rsp_fsm_upt_used; // NB cycles UPT LOCK used 549 uint32_t m_cpt_multi_ack_fsm_upt_used; // NB cycles UPT LOCK used 550 uint32_t m_cpt_cleanup_fsm_ivt_used; // NB cycles UPT LOCK used 551 uint32_t m_cpt_cas_fsm_upt_used; // NB cycles UPT LOCK used 528 552 529 uint32_t m_cpt_write_fsm_upt_used; // NB cycles UPT LOCK used 530 uint32_t m_cpt_xram_rsp_fsm_upt_used; // NB cycles UPT LOCK used 531 uint32_t m_cpt_multi_ack_fsm_upt_used; // NB cycles UPT LOCK used 532 uint32_t m_cpt_cleanup_fsm_ivt_used; // NB cycles UPT LOCK used 533 uint32_t m_cpt_cas_fsm_upt_used; // NB cycles UPT LOCK used 553 uint32_t m_cpt_ivt_unused; // NB cycles UPT LOCK unused 554 uint32_t m_cpt_upt_unused; // NB cycles UPT LOCK unused 555 556 uint32_t m_cpt_read_fsm_heap_lock; // wait HEAP LOCK 557 uint32_t m_cpt_write_fsm_heap_lock; // wait HEAP LOCK 558 uint32_t m_cpt_cas_fsm_heap_lock; // wait HEAP LOCK 559 uint32_t m_cpt_cleanup_fsm_heap_lock; // wait HEAP LOCK 560 uint32_t m_cpt_xram_rsp_fsm_heap_lock; // wait HEAP LOCK 534 561 535 uint32_t m_cpt_ivt_unused; // NB cycles UPT LOCK unused 536 uint32_t m_cpt_upt_unused; // NB cycles UPT LOCK unused 537 538 uint32_t m_cpt_read_fsm_heap_lock; // wait HEAP LOCK 539 uint32_t m_cpt_write_fsm_heap_lock; // wait HEAP LOCK 540 uint32_t m_cpt_cas_fsm_heap_lock; // wait HEAP LOCK 541 uint32_t m_cpt_cleanup_fsm_heap_lock; // wait HEAP LOCK 542 uint32_t m_cpt_xram_rsp_fsm_heap_lock; // wait HEAP LOCK 562 uint32_t m_cpt_read_fsm_n_heap_lock; // NB HEAP LOCK 563 uint32_t m_cpt_write_fsm_n_heap_lock; // NB HEAP LOCK 564 uint32_t m_cpt_cas_fsm_n_heap_lock; // NB HEAP LOCK 565 uint32_t m_cpt_cleanup_fsm_n_heap_lock; // NB HEAP LOCK 566 uint32_t m_cpt_xram_rsp_fsm_n_heap_lock; // NB HEAP LOCK 543 567 544 uint32_t m_cpt_read_fsm_n_heap_lock; // NB HEAP LOCK545 uint32_t m_cpt_write_fsm_n_heap_lock; // NB HEAP LOCK546 uint32_t m_cpt_cas_fsm_n_heap_lock; // NB HEAP LOCK547 uint32_t m_cpt_cleanup_fsm_n_heap_lock; // NB HEAP LOCK548 uint32_t m_cpt_xram_rsp_fsm_n_heap_lock; // NB HEAP LOCK568 uint32_t m_cpt_read_fsm_heap_used; // NB cycles HEAP LOCK used 569 uint32_t m_cpt_write_fsm_heap_used; // NB cycles HEAP LOCK used 570 uint32_t m_cpt_cas_fsm_heap_used; // NB cycles HEAP LOCK used 571 uint32_t m_cpt_cleanup_fsm_heap_used; // NB cycles HEAP LOCK used 572 uint32_t m_cpt_xram_rsp_fsm_heap_used; // NB cycles HEAP LOCK used 549 573 550 uint32_t m_cpt_read_fsm_heap_used; // NB cycles HEAP LOCK used 551 uint32_t m_cpt_write_fsm_heap_used; // NB cycles HEAP LOCK used 552 uint32_t m_cpt_cas_fsm_heap_used; // NB cycles HEAP LOCK used 553 uint32_t m_cpt_cleanup_fsm_heap_used; // NB cycles HEAP LOCK used 554 uint32_t m_cpt_xram_rsp_fsm_heap_used; // NB cycles HEAP LOCK used 555 556 uint32_t m_cpt_heap_unused; // NB cycles HEAP LOCK unused 557 uint32_t m_cpt_heap_slot_available; // NB HEAP slot available refresh at each cycles 558 uint32_t m_cpt_heap_min_slot_available; // NB HEAP : Min of slot available 559 560 //RWT 561 uint32_t m_cpt_cleanup_data; 562 uint32_t m_cpt_ncc_to_cc_read; // NB change from NCC to CC caused by a READ 563 uint32_t m_cpt_ncc_to_cc_write; // NB change from NCC to CC caused by a WRITE 564 565 uint32_t m_cpt_read_data_unc; 566 uint32_t m_cpt_read_data_miss_CC; 567 uint32_t m_cpt_read_ins_unc; 568 uint32_t m_cpt_read_ins_miss; 569 uint32_t m_cpt_read_ll_CC; 570 uint32_t m_cpt_read_data_miss_NCC; 571 uint32_t m_cpt_read_ll_NCC; 572 uint32_t m_cpt_read_WTF; 573 574 uint32_t m_cpt_update_flits; // Number of flits for UPDATEs 575 uint32_t m_cpt_inval_cost; // Number of (flits * distance) for INVALs 576 577 uint32_t m_cpt_get; 578 uint32_t m_cpt_put; 579 580 size_t m_prev_count; 574 uint32_t m_cpt_read_data_unc; 575 uint32_t m_cpt_read_data_miss_CC; 576 uint32_t m_cpt_read_ins_unc; 577 uint32_t m_cpt_read_ins_miss; 578 uint32_t m_cpt_read_ll_CC; 579 uint32_t m_cpt_read_data_miss_NCC; 580 uint32_t m_cpt_read_ll_NCC; 581 582 size_t m_prev_count; 581 583 582 584 protected:
Note: See TracChangeset
for help on using the changeset viewer.