Bes Posted April 6, 2020 Report Share Posted April 6, 2020 Hello , i have a compile error that I don’t seem to understand, can someone help Quote Link to comment Share on other sites More sharing options...
Bes Posted April 7, 2020 Author Report Share Posted April 7, 2020 I’m using sc_has_process constructor in the header file. i have an output port and 2 signals( my inputs that i want to read from csv file but I can’t) , so in the header file i only initialize my output port, 2 signals and my method in the .cpp file, i do convolution between the two input signals which are used as 2D arrays using nested sc_vector. then in the main method i write convLayer c(“ “); // convLayer is my module name. c.in1(array) ; //in1 is the signal in the header file, array is a new signal with same size in main.cpp file Quote Link to comment Share on other sites More sharing options...
David Black Posted April 7, 2020 Report Share Posted April 7, 2020 You really should not use an empty string for the instance name. Quote Link to comment Share on other sites More sharing options...
Bes Posted April 7, 2020 Author Report Share Posted April 7, 2020 Isn’t this required for the constructor? Quote Link to comment Share on other sites More sharing options...
David Black Posted April 7, 2020 Report Share Posted April 7, 2020 Yes, but you need to use a real string (not empty). Usually, the instance name matches the name of the instance itself. For example: #include "top_module.cpp" //< Real code goes in here #include <systemc> // Minimal sc_main function int sc_main(int argc, const char* argv[]) { Top_module top_instance{ "top_instance" }; sc_core::sc_start(); return 0; } Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.