Jump to content

Cannot install FC4SC(functional coverage for systemC)


Recommended Posts

I've build a systemC environment and now I want to get the coverage. I found that this library could be used.

I'm trying to install FC4SC library (https://github.com/amiq-consulting/fc4sc)

And this is tested by google test. when I do following the guideline (https://github.com/amiq-consulting/fc4sc/blob/master/docs/FC4SC_User_Guide.pdf) on page 13

At the beginning I use the command "cmake -DBUILD_GTEST=ON BUILD_GTEST -DBUILD_SHARED_LIBS=ON .." as the guideline shows, and it doesn't work, it the show as below:

-bash $'cmake\342\200\213 command not found

 

Then I realized that cmake has been installed and it should be used by run cmake.exe, and it shows like this

cmake -DBUILD_GTEST=ON BUILD_GTEST -DBUILD_SHARED_LIBS=ON ..
-- The C compiler identification is GNU 9.3.0
-- The CXX compiler identification is GNU 9.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- broken
CMake Error at /usr/share/cmake-3.14.5/Modules/CMakeTestCCompiler.cmake:60 (message):
  The C compiler

    "/usr/bin/cc"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: /cygdrive/d/SystemC/7_UVM/Coverage/fc4sc-master/test/googletest/build/CMakeFiles/CMakeTmp

    Run Build Command(s):/usr/bin/make.exe cmTC_694fb/fast




  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:4 (project)


-- Configuring incomplete, errors occurred!
See also "/cygdrive/d/SystemC/7_UVM/Coverage/fc4sc-master/test/googletest/build/CMakeFiles/CMakeOutput.log".
See also "/cygdrive/d/SystemC/7_UVM/Coverage/fc4sc-master/test/googletest/build/CMakeFiles/CMakeError.log".

The CMakeError.log is attached to this post

I tried to reinstall compiler and some other component that could be relevant, I found some topic has similar situation but there's no hope.

Could anyone help me overcome this?

 

 

CMakeError.log

Link to post
Share on other sites

Hello @Viet Hoang,

Can you clarify what environment you are using for setting the build environment for both SystemC and fc4sc? (From the looks of it it seems to be cygwin based).

Also the error:

2 hours ago, Viet Hoang said:

-bash $'cmake\342\200\213 command not found

Is due to you trying to copy and paste the command from the pdf to the bash console.

Can you try to manually type the commands?

Regards,

Ameya Vikram Singh

Link to post
Share on other sites

HI @AmeyaVS,

Is due to you trying to copy and paste the command from the pdf to the bash console.

Thank your for your information!

I uninstalled and deleted all thing that related to cygwin and reinstall cygwin and libraries again, and it works, I've installed fc4sc library successfully 

But now, I encountered issue with systemC library. This project work well before and now I used it to test the new library.

The simulation has been stopped at sc_start, i dont know why and there's no further information has been printed.

This is the code of the man function

#include <iostream>
#include "scpu_testbench.h"
int sc_main (int argc, char* argv[]) {
  //1. Internal signal declaration
  sc_signal <bool> rst_n;
  //2. Create the clock 
  //Cycle: 2 ns
  //Duty cycle: 50%
  sc_clock clk("clk", 2, SC_NS, 0.5);
  //3. Instances
  scpu_testbench scpu_testbench_inst("scpu_testbench_inst");
    scpu_testbench_inst.clk(clk);
  //4. Create VCD file to trace
  #include "scpu_trace.h"
  //5. Start simulation
  cout << "3.Start simulation" << endl;
  int count = 0;
  for (int i = 0; i < 100; i++) {
    cout << "Simulation is running " << i << endl;
    sc_start(2, SC_NS); //One cycle, the simulation has been stopped here
  }
  //6. Close the waveform file
  sc_close_vcd_trace_file (scpu_waveform);
  //7. END
  return 0;
}

 

It should be counting up and keep running until the for loop ended but it stops that is showed in the picture

image.png.ad3186aa4a9f796e14d0d9a26832b831.png

Could you please help me with this?

 

Link to post
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...