data/full_repos/permissive/140493787/src/hdl/circle_checker.v
1: b'%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:34: Unsupported: Ignoring delay on this delayed statement.\n      xCoord <= 10\'d0;   yCoord <= 10\'d0;   #10;\n                                            ^\n                  ... Use "/* verilator lint_off STMTDLY */" and lint_on around source to disable this message.\n%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:35: Unsupported: Ignoring delay on this delayed statement.\n      xCoord <= 10\'d472;                    #10;\n                                            ^\n%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:36: Unsupported: Ignoring delay on this delayed statement.\n                         yCoord <= 10\'d472; #10;\n                                            ^\n%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:37: Unsupported: Ignoring delay on this delayed statement.\n      xCoord <= 10\'d333;                    #10;\n                                            ^\n%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:38: Unsupported: Ignoring delay on this delayed statement.\n                         yCoord <= 10\'d333; #10;\n                                            ^\n%Warning-STMTDLY: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:39: Unsupported: Ignoring delay on this delayed statement.\n      xCoord <= 10\'d400;                    #10;\n                                            ^\n%Warning-WIDTH: data/full_repos/permissive/140493787/src/hdl/circle_checker.v:23: Operator LTE expects 20 bits on the RHS, but RHS\'s VARREF \'CIRCLE_RADIUS_SQUARED\' generates 18 bits.\n                                                                                : ... In instance circle_checker_testbench.dut\n      isInside = squaredSum <= CIRCLE_RADIUS_SQUARED;\n                            ^~\n%Error: Exiting due to 7 warning(s)\n        ... See the manual and https://verilator.org for more assistance.\n'
module circle_checker (
   output reg        isInside,
   input  wire [9:0] xCoord,
   input  wire [9:0] yCoord
);

   parameter CIRCLE_RADIUS_SQUARED = 18'h3_8400;

   reg [18:0] xSquared, ySquared;
   reg [19:0] squaredSum;
   
   always @ (*) begin
      xSquared = xCoord * xCoord;
      ySquared = yCoord * yCoord;
      squaredSum = xSquared + ySquared;
      isInside = squaredSum <= CIRCLE_RADIUS_SQUARED;
   end
endmodule
module circle_checker (
   output reg        isInside,
   input  wire [9:0] xCoord,
   input  wire [9:0] yCoord
);


   parameter CIRCLE_RADIUS_SQUARED = 18'h3_8400;

   reg [18:0] xSquared, ySquared;
   reg [19:0] squaredSum;
   
   always @ (*) begin
      xSquared = xCoord * xCoord;
      ySquared = yCoord * yCoord;
      squaredSum = xSquared + ySquared;
      isInside = squaredSum <= CIRCLE_RADIUS_SQUARED;
   end
endmodule