Comments (4)
I'm working on this and have gotten to the point where I can use the system version of tcl/tk 8.6 itcl/itk 3.4 on Ubuntu. I've some polishing up to do, but hopefully it shouldn't take too much longer.
from bsc.
It's a bit worse than that. bsc currently vendors 8.5.4 which is from 2008. The latest version of 8.5 is 8.5.19 from 2016.
From talking to a former bsc developer, I believe the vendored Tcl/Tk has patches to the core Tcl code to allow the Bluesim/Haskell integrationrather than doing it with a Tcl extension. We need to verify if this is the case, but if it is, we need to resolve this before we can use the/a system Tcl.
from bsc.
There seems to be two main differences between a stock version of tcl 8.5.4 and what is shipped in this repository:
diff --no-dereference -u -r ./upstream/tcl8.5.4/generic/tclIO.c ./tcltk8.5.4/tcl8.5.4/generic/tclIO.c
--- ./upstream/tcl8.5.4/generic/tclIO.c 2008-05-23 16:10:43.000000000 -0500
+++ ./tcltk8.5.4/tcl8.5.4/generic/tclIO.c 2020-02-06 13:52:29.621490343 -0600
@@ -6232,6 +6232,7 @@
SetFlag(statePtr, CHANNEL_EOF);
statePtr->inputEncodingFlags |= TCL_ENCODING_END;
} else if (nread < 0) {
+ if (result == 512) result = EAGAIN; /* work around Linux kernel bug */
if ((result == EWOULDBLOCK) || (result == EAGAIN)) {
SetFlag(statePtr, CHANNEL_BLOCKED);
result = EAGAIN;
and
diff --no-dereference -u -r ./upstream/tcl8.5.4/unix/Makefile.in ./tcltk8.5.4/tcl8.5.4/unix/Makefile.in
--- ./upstream/tcl8.5.4/unix/Makefile.in 2008-08-14 12:31:38.000000000 -0500
+++ ./tcltk8.5.4/tcl8.5.4/unix/Makefile.in 2020-02-06 13:52:29.682491436 -0600
@@ -6,6 +6,12 @@
#
# RCS: @(#) $Id: Makefile.in,v 1.229.2.8 2008/08/13 23:07:16 das Exp $
+# Bluespec added:
+# Use vfork instead of fork, as this is much more efficient especially
+# for large memory images in bluewish.
+# fork/vfork is used in the exec tclcommand, to launch other processes.
+EXTRA_CFLAGS += -DUSE_VFORK
+
VERSION = @TCL_VERSION@
MAJOR_VERSION = @TCL_MAJOR_VERSION@
MINOR_VERSION = @TCL_MINOR_VERSION@
The "linux kernel bug" is entirely unclear, and the usage of vfork(2)
is more obvious but still somewhat unexplained by what parameters it can be triggered under, as the Linux memory manager probably changed a lot since this was initially patched.
At the very least, this is hopefully an indication that using the system tcl isn't impossible/extremely difficult, but some more investigation/testing would be needed.
from bsc.
Done by PR #78. This will need to be tested with OSes other than Ubuntu 16.04/18.04
from bsc.
Related Issues (20)
- bsc ignores `always_ready` when checking for duplicate wires
- module verilog does not allow sharing ports among conflicting methods
- Improve the mechanism for testing Bluespec Inc bug 1490 HOT 3
- `-dparsed` output produces invalid register updates with BSV HOT 2
- `-dparsed` produces invalid BSV module function that takes another module as an argument HOT 2
- Missing `Ord Bool` instance HOT 7
- Static check of file descriptor argument to tasks like $fgetc HOT 3
- Testsuite reports an error getting BSC version HOT 2
- Internal Compiler Error when quoting a character value. HOT 4
- Bluesim's symbol-probing interface has wrong values for FIFO
- Unresolved numeric contexts that should be resolvable HOT 6
- Verilog import fails in macro substitution HOT 2
- Unexpected syntax error HOT 1
- expandPorts.tcl has hardcoded paths which do not exist. HOT 1
- Unexpected behavior in Stmt sequence when using par HOT 2
- Bluesim divide-by-zero behavior is inconsistent on arm64 HOT 2
- Type synonyms with phantom parameters can lead to strange behaviors (E.g., compiler hang) HOT 4
- doc example for mkUniqueWrapper2 HOT 6
- -remove-unused-modules flag doesn't work with mkProbe module provided in std library HOT 2
- Failures with compilation on raspberry-pi 5 HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bsc.