Ignore:
Timestamp:
Dec 16, 2008, 5:24:26 PM (15 years ago)
Author:
rosiere
Message:

1) Update Prediction Table - New architecture (systemC) done (and tested) -> need change interface in top level
2) Change documentation on VHDL generation
3) Change VHDL constant (case std_logic and std_logic_vector)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/src/Vhdl_std_logic.cpp

    r94 r95  
    1010#include <math.h>
    1111#include "Behavioural/include/Vhdl.h"
     12#include "Common/include/ToBase2.h"
    1213
    1314namespace morpheo              {
     
    5758
    5859    return _return;
     60  };
     61
     62#undef  FUNCTION
     63#define FUNCTION "Vhdl::std_logic_cst"
     64  std::string std_logic_cst (uint32_t size, uint32_t value)
     65  {
     66    log_printf(FUNC,Behavioural,FUNCTION,"Begin");
     67
     68    std::string conv;
     69
     70    if (size == 1)
     71      conv = "'"+toString(value&1)+"'";
     72    else
     73      conv = "\""+toBase2<uint32_t>(value,size)+"\"";
     74
     75    log_printf(FUNC,Behavioural,FUNCTION,"End");
     76
     77    return conv;
    5978  };
    6079
Note: See TracChangeset for help on using the changeset viewer.