WAL enables programmable waveform analysis.

Related tags

Data Analysiswal
Overview

This repro introcudes the Waveform Analysis Language (WAL). The initial paper on WAL will appear at ASPDAC'22 and can be downloaded here: https://www.ics.jku.at/files/2022ASPDAC_WAL.pdf. The examples from the paper can be found in the examples folder.

If you like WAL you can cite our paper as follows:

@InProceedings{KG:2022,
  author        = {Lucas Klemmer and Daniel Gro{\ss}e},
  title         = {{WAL:} A Novel Waveform Analysis Language for Advanced Design Understanding and Debugging},
  booktitle     = {ASP Design Automation Conf.},
  year          = 2022
}

Comments
  • WAL fails to load FST

    WAL fails to load FST

    I'm trying to load an FST but get the following error:

    >-> (load "sim_no_pfb_match.fst" "waves")
    'utf-8' codec can't decode byte 0x83 in position 14: invalid start byte
    (load "sim_no_pfb_match.fst" "waves")
    

    The FST loads into gtkwave without issue so is there anything I can do to help debug this?

    opened by shareefj 10
  • [Question] Is WAL able to load Synopsys .vpd files?

    [Question] Is WAL able to load Synopsys .vpd files?

    I am playing around with the tool and wanted to do some analysis of my simulations of the BOOM core. I simulated the core using Chipyard and Synopsys VCS and get the according vpd files, which I can't load into WAL (throwing following error message)

    'utf-8' codec can't decode byte 0xd5 in position 21: invalid continuation byte

    It is possible to convert it to a vcd file by using vpd2vcd but since it is less compressed the vcd files become really large(e.g. 27 MB converted to 2.2 GB)

    Is there a possibility to use vpd files without converting to vcd?

    Best regards, Alex

    opened by WezelA 5
  • [wawk] using 2-digit number in sliced_symbol leads to error

    [wawk] using 2-digit number in sliced_symbol leads to error

    When I try to access a sliced part of a 32bit signal (e.g. inst[11:7]) I get the following error:

    Traceback (most recent call last):
      File "/home/eyck/tmp/wal/.wal/bin/wawk", line 33, in <module>
        sys.exit(load_entry_point('wal-lang', 'console_scripts', 'wawk')())
      File "/home/eyck/git/wal/wawk/wawk.py", line 70, in run
        wal.eval(statement.action)
      File "/home/eyck/git/wal/wal/core.py", line 43, in eval
        return self.eval_context.eval(sexpr)
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 290, in op_do
        return seval.eval_args(args)[-1]
      File "/home/eyck/git/wal/wal/eval.py", line 40, in eval_args
        return list(map(self.eval, args))
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 239, in op_if
        return seval.eval(args[1])
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 290, in op_do
        return seval.eval_args(args)[-1]
      File "/home/eyck/git/wal/wal/eval.py", line 40, in eval_args
        return list(map(self.eval, args))
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 194, in op_set
        res = seval.eval(arg[1])
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 91, in op_neq
        evaluated = seval.eval_args(args)
      File "/home/eyck/git/wal/wal/eval.py", line 40, in eval_args
        return list(map(self.eval, args))
      File "/home/eyck/git/wal/wal/eval.py", line 93, in eval
        res = self.eval_dispatch(head, tail)
      File "/home/eyck/git/wal/wal/eval.py", line 44, in eval_dispatch
        return self.dispatch.get(oprtr.value, lambda a, b: NotImplementedError())(self, args)
      File "/home/eyck/git/wal/wal/implementation/core.py", line 609, in op_slice
        return (evaluated[0] & (((1 << (upper - lower + 1)) - 1) << lower)) >> lower
    ValueError: negative shift count
    
    opened by eyck 2
  • [wawk] output is not reliable

    [wawk] output is not reliable

    When running the following script

    BEGIN: {
        // import python file for access to riscvmodel lib
        import(extern);
        icnt=0;
        lastclkcnt=0;
        clkcnt=0;
        printed=0;
        ilen = 0;
        // create some aliases for shorter signal names
        alias(clk, tb.adapter.core.TGC_C.clk);
        alias(reset, tb.adapter.core.TGC_C.reset);
        alias(trap, tb.adapter.core.TGC_C.core_trace_exc_o);
        alias(valid, tb.adapter.core.TGC_C.core_trace_valid_o);
        alias(instr, tb.adapter.core.TGC_C.core_trace_instr_o);
        alias(pc, tb.adapter.core.TGC_C.core_trace_pc_o);
        alias(reg_addr, tb.adapter.core.TGC_C.core_trace_reg_addr_o);
        alias(reg_val, tb.adapter.core.TGC_C.core_trace_reg_val_o);
        alias(reg_wr, tb.adapter.core.TGC_C.core_trace_reg_wr_o);
    }
    clk, valid: {
        if(printed==0) {
            icnt=icnt+1;
            delay=(clkcnt-lastclkcnt)/2;
            lastclkcnt=clkcnt;
            op = call(extern.decode, instr);
            shifted = instr/128;
            was_call = shifted[4:0]!=0 && (op == "jal" || op == "jalr");
            ilen = 2;
            if (instr[1:0]==3)
              ilen = 4;
            printf("0x%x, %d, %d, %d, 0x%x, %s\n", pc, delay, ilen, was_call, instr, op);
            printed = 1;
        } else
            printed = 0;
    }
    clk, !reset: {
        clkcnt=clkcnt+1;
    }
    END: {
        printf("%f (%d/%d)\n", icnt/clkcnt, icnt, clkcnt);
    }
    

    on a vcd file I get in 2 consecutive runs

    (.wal) eyck$:~/tmp/wal$ wawk cpi.wawk ../vtgc_tb_xlevel.vcd
    0x20, 3, 4, 1, 0x297, auipc
    0x24, 1, 4, 1, 0xc028293, addi
    0x28, 1, 4, 0, 0x30529073, csrrw
    0x2c, 1, 4, 1, 0x2a00093, addi
    0x30, 1, 4, 1, 0x2a00113, addi
    0x34, 1, 4, 1, 0x2a00193, addi
    0x38, 1, 4, 1, 0x200513, addi
    0x3a, 1, 4, 1, 0x300a13, addi
    0x3e, 1, 4, 1, 0x700f93, addi
    0x40, 1, 4, 0, 0x43507b, 4411515
    0.000000 (10/28)
    (.wal) eyck$:~/tmp/wal$ wawk cpi.wawk ../vtgc_tb_xlevel.vcd
    0x20, 3, 4, 0, 0x297, auipc
    0x24, 1, 4, 0, 0xc028293, addi
    0x28, 1, 4, 0, 0x30529073, csrrw
    0x2c, 1, 4, 0, 0x2a00093, addi
    0x30, 1, 4, 0, 0x2a00113, addi
    0x34, 1, 4, 0, 0x2a00193, addi
    0x38, 1, 4, 0, 0x200513, addi
    0x3a, 1, 4, 0, 0x300a13, addi
    0x3e, 1, 4, 0, 0x700f93, addi
    0x40, 1, 4, 0, 0x43507b, 4411515
    0.000000 (10/28)
    
    bug 
    opened by eyck 1
  • Changed wawk semicolon behaviour slightly

    Changed wawk semicolon behaviour slightly

    Updated the wawk grammar in a way where semicolon usage is now more consistent:

    • there are no longer weird cases where some "{" blocks "}" require a semicolon after them, while others do not: now none of them require semicolons, but they (as well as other statements) can have as many semicolons after them as they like
    • BREAKING CHANGE: if/else statements that DO NOT use blocks but one-line statements instead, now require semicolons for each statement, and not just the last one.
    opened by FRoith 0
  • ACTUALLY fixed the precedence rules this time

    ACTUALLY fixed the precedence rules this time

    Addresses #2, where a non-precise grammar caused non-deterministic (and incorrect) parsing behavior.

    Previous pull request was thought to fix the issue due to faulty tests, but this time it actually fixed the issue correctly as far as I can tell.

    opened by FRoith 0
  • Package does not declare all dependencies

    Package does not declare all dependencies

    When installing wal using pip on a CentOS7 OS and runnign wawk I get:

    Traceback (most recent call last):
    File "/home/xxx/git/TGC-UVM/riscv-dv-venv/bin/wawk", line 5, in <module>
    from wawk.wawk import run
    File "/home/xxx/git/TGC-UVM/riscv-dv-venv/lib64/python3.6/site-packages/wawk/[wawk.py](http://wawk.py/)", line 6, in <module>
    from wal.core import Wal
    File "/home/xxx/git/TGC-UVM/riscv-dv-venv/lib64/python3.6/site-packages/wal/[core.py](http://core.py/)", line 7, in <module>
    from wal.eval import SEval
    File "/home/xxx/git/TGC-UVM/riscv-dv-venv/lib64/python3.6/site-packages/wal/[eval.py](http://eval.py/)", line 2, in <module>
    from wal.ast_defs import Operator, Symbol, ExpandGroup
    File "/home/xxx/git/TGC-UVM/riscv-dv-venv/lib64/python3.6/site-packages/wal/ast_[defs.py](http://defs.py/)", line 2, in <module>
    from dataclasses import dataclass
    ModuleNotFoundError: No module named 'dataclasses'
    

    After running pip3 install dataclasses everything works fine.

    opened by eyck 0
  • Upgrade version of vcdvcd

    Upgrade version of vcdvcd

    Hi,

    you seem to be depending on a broken version of vcdvcd.py. After pip installing wal-lang, I get the following error:

    (.venv) [email protected]:~/git/wal$ wal
    Traceback (most recent call last):
      File "/home/shareefj/git/wal/.venv/bin/wal", line 5, in <module>
        from wal.wal import run
      File "/home/shareefj/git/wal/.venv/lib/python3.10/site-packages/wal/wal.py", line 7, in <module>
        from wal.core import Wal
      File "/home/shareefj/git/wal/.venv/lib/python3.10/site-packages/wal/core.py", line 6, in <module>
        from wal.trace import TraceContainer
      File "/home/shareefj/git/wal/.venv/lib/python3.10/site-packages/wal/trace.py", line 5, in <module>
        from vcdvcd import VCDVCD, StreamParserCallbacks
      File "/home/shareefj/git/wal/.venv/lib/python3.10/site-packages/vcdvcd/__init__.py", line 1, in <module>
        from .vcdvcd import *
      File "/home/shareefj/git/wal/.venv/lib/python3.10/site-packages/vcdvcd/vcdvcd.py", line 355, in <module>
        class Scope(collections.MutableMapping):
    AttributeError: module 'collections' has no attribute 'MutableMapping'
    

    and it looks like at some point they've tried to fix this: https://github.com/cirosantilli/vcdvcd/commit/9c9b7c1aaa7a6bcc4e254e3557cc00a9ec1c7bd0

    opened by shareefj 1
Releases(v0.6.3-beta.2)
Owner
Institute for Complex Systems (ICS), Johannes Kepler University Linz
ICS conducts research in EDA with focus on verification, debugging, and synthesis; abstraction levels: SystemC virtual prototypes, RTL downto gate-level.
Institute for Complex Systems (ICS), Johannes Kepler University Linz
This module is used to create Convolutional AutoEncoders for Variational Data Assimilation

VarDACAE This module is used to create Convolutional AutoEncoders for Variational Data Assimilation. A user can define, create and train an AE for Dat

Julian Mack 23 Dec 16, 2022
Predictive Modeling & Analytics on Home Equity Line of Credit

Predictive Modeling & Analytics on Home Equity Line of Credit Data (Python) HMEQ Data Set In this assignment we will use Python to examine a data set

Dhaval Patel 1 Jan 09, 2022
Additional tools for particle accelerator data analysis and machine information

PyLHC Tools This package is a collection of useful scripts and tools for the Optics Measurements and Corrections group (OMC) at CERN. Documentation Au

PyLHC 3 Apr 13, 2022
Data analysis and visualisation projects from a range of individual projects and applications

Python-Data-Analysis-and-Visualisation-Projects Data analysis and visualisation projects from a range of individual projects and applications. Python

Tom Ritman-Meer 1 Jan 25, 2022
Improving your data science workflows with

Make Better Defaults Author: Kjell Wooding [email protected] This is the git re

Kjell Wooding 18 Dec 23, 2022
Open-source Laplacian Eigenmaps for dimensionality reduction of large data in python.

Fast Laplacian Eigenmaps in python Open-source Laplacian Eigenmaps for dimensionality reduction of large data in python. Comes with an wrapper for NMS

17 Jul 09, 2022
A Python package for Bayesian forecasting with object-oriented design and probabilistic models under the hood.

Disclaimer This project is stable and being incubated for long-term support. It may contain new experimental code, for which APIs are subject to chang

Uber Open Source 1.6k Dec 29, 2022
Python for Data Analysis, 2nd Edition

Python for Data Analysis, 2nd Edition Materials and IPython notebooks for "Python for Data Analysis" by Wes McKinney, published by O'Reilly Media Buy

Wes McKinney 18.6k Jan 08, 2023
Universal data analysis tools for atmospheric sciences

U_analysis Universal data analysis tools for atmospheric sciences Script written in python 3. This file defines multiple functions that can be used fo

Luis Ackermann 1 Oct 10, 2021
ETL pipeline on movie data using Python and postgreSQL

Movies-ETL ETL pipeline on movie data using Python and postgreSQL Overview This project consisted on a automated Extraction, Transformation and Load p

Juan Nicolas Serrano 0 Jul 07, 2021
A Python module for clustering creators of social media content into networks

sm_content_clustering A Python module for clustering creators of social media content into networks. Currently supports identifying potential networks

72 Dec 30, 2022
Created covid data pipeline using PySpark and MySQL that collected data stream from API and do some processing and store it into MYSQL database.

Created covid data pipeline using PySpark and MySQL that collected data stream from API and do some processing and store it into MYSQL database.

2 Nov 20, 2021
The micro-framework to create dataframes from functions.

The micro-framework to create dataframes from functions.

Stitch Fix Technology 762 Jan 07, 2023
Collections of pydantic models

pydantic-collections The pydantic-collections package provides BaseCollectionModel class that allows you to manipulate collections of pydantic models

Roman Snegirev 20 Dec 26, 2022
Active Learning demo using two small datasets

ActiveLearningDemo How to run step one put the dataset folder and use command below to split the dataset to the required structure run utils.py For ea

3 Nov 10, 2021
A python package which can be pip installed to perform statistics and visualize binomial and gaussian distributions of the dataset

GBiStat package A python package to assist programmers with data analysis. This package could be used to plot : Binomial Distribution of the dataset p

Rishikesh S 4 Oct 17, 2022
Datashredder is a simple data corruption engine written in python. You can corrupt anything text, images and video.

Datashredder is a simple data corruption engine written in python. You can corrupt anything text, images and video. You can chose the cha

2 Jul 22, 2022
A simplified prototype for an as-built tracking database with API

Asbuilt_Trax A simplified prototype for an as-built tracking database with API The purpose of this project is to: Model a database that tracks constru

Ryan Pemberton 1 Jan 31, 2022
Orchest is a browser based IDE for Data Science.

Orchest is a browser based IDE for Data Science. It integrates your favorite Data Science tools out of the box, so you don’t have to. The application is easy to use and can run on your laptop as well

Orchest 3.6k Jan 09, 2023
Finding project directories in Python (data science) projects, just like there R rprojroot and here packages

Find relative paths from a project root directory Finding project directories in Python (data science) projects, just like there R here and rprojroot

Daniel Chen 102 Nov 16, 2022