Skip to content
Snippets Groups Projects
Commit e3d177be authored by Daniela Genius's avatar Daniela Genius
Browse files

bugfix

parent c11c26ad
No related branches found
No related tags found
No related merge requests found
......@@ -67,11 +67,25 @@ tmpl()::VciMwmrStats(
for ( typename std::vector<std::string>::const_iterator i = fifo_name.begin();
i != fifo_name.end();
++i ) {
const std::string name = (*i)+"_status";
const soclib::common::BinaryFileSymbol *sym = loader.get_symbol_by_name(name);
if ( ! sym || sym->name() != name ) {
std::cerr << this->name() << " name not found: " << name << std::endl;
continue;
}
typename vci_param::fast_addr_t addr = sym->address();
std::cout << " mwmr fifo with status address " << addr << std::endl;
m_mwmr_info.push_back( mwmr_info_t(addr, *i) );
}
const std::string name2 = (*i);
loader.get_symbol_by_name(name2);
const soclib::common::BinaryFileSymbol *sym2 = loader.get_symbol_by_name(name2);
std::cout << " mwmr fifo with address " << sym2->address() << std::endl;
/* for ( typename std::vector<std::string>::const_iterator i = fifo_name.begin();
i != fifo_name.end();
++i ) {
const std::string name2 = (*i);
loader.get_symbol_by_name(name2);
const soclib::common::BinaryFileSymbol *sym2 = loader.get_symbol_by_name(name2);
std::cout << " mwmr fifo with address " << sym2->address() << std::endl;
const std::string name = (*i)+"_status";
const soclib::common::BinaryFileSymbol *sym = loader.get_symbol_by_name(name);
......@@ -82,7 +96,7 @@ std::cout << " mwmr fifo with address " << sym2->address() << std::endl;
typename vci_param::fast_addr_t addr = sym->address();
std::cout << " mwmr fifo with status address " << addr << std::endl;
m_mwmr_info.push_back( mwmr_info_t(addr, *i) );
}
}*/
}
tmpl()::~VciMwmrStats()
......@@ -145,7 +159,7 @@ tmpl(void)::handle_txn(const VciLoggerElem<vci_param> &elem, const mwmr_info_t &
//prefix(elem, mwmr) << "WDATA" << std::hex<< wdata<<std::endl;
//if ( wdata == 0x1) {
if ( wdata >= 1 ) {
if ( wdata >= 1 ) {
if ( rdata == vci_param::STORE_COND_ATOMIC ){
prefix(elem, mwmr) << "lock_take" << std::endl;
......
......@@ -96,7 +96,7 @@ void destroyAsyncchannel(asyncchannel *asyncch) {
debugInt("asyncchannel read: address \n",channel->mwmr_fifo);
debugInt("asyncchannel fifo->depth \n",channel->mwmr_fifo->depth);
debugInt("asyncchannel fifo->width \n",channel->mwmr_fifo->width);
debugInt("asyncchannel msg size \n",sizeof(*msg));
debugInt("asyncchannel msg size \n",channel->mwmr_fifo->width);
// async_read(channel->mwmr_fifo, &msg, 1);
async_read(channel->mwmr_fifo, &msg, channel->mwmr_fifo->width);
return msg;
......@@ -111,7 +111,7 @@ void destroyAsyncchannel(asyncchannel *asyncch) {
channel->currentNbOfMessages = channel->currentNbOfMessages -1;
previous->next = NULL;
debugInt("before async read 1\n");
debugInt("asyncchannel address \n",channel->mwmr_fifo);
debugInt("asyncchannel fifo->depth \n",channel->mwmr_fifo->depth);
debugInt("asyncchannel fifo->width \n",channel->mwmr_fifo->width);
......@@ -136,6 +136,7 @@ void addMessageToAsyncChannel(asyncchannel *channel, message *msg) {
debugInt("asyncchannel->fifo rptr \n", channel->mwmr_fifo->status->rptr);
debugInt("asyncchannel->fifo wptr \n", channel->mwmr_fifo->status->wptr);
//async_write(channel->mwmr_fifo, &msg, 1 );
debugInt("asyncchannel fifo->width \n",channel->mwmr_fifo->width);
debugInt("asyncchannel msg size \n", channel->mwmr_fifo->width);
async_write(channel->mwmr_fifo, &msg, channel->mwmr_fifo->width);//DG 13.6. *msg au lieu de msg//DG 18.07. fifo width
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment