Text Generation
PEFT
Safetensors
verilog
rtl
code-generation
qwen2.5-coder
lora
qlora
hardware
verilog-eval
conversational
Instructions to use Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-Coder-7B-Instruct") model = PeftModel.from_pretrained(base_model, "Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora") - Notebooks
- Google Colab
- Kaggle
Upload v30b delta-distilled Verilog LoRA adapter with scripts and results
Browse files- .gitattributes +1 -0
- README.md +139 -0
- adapter_config.json +48 -0
- adapter_model.safetensors +3 -0
- chat_template.jinja +54 -0
- documentation/v30b_delta_distillation_plan.md +67 -0
- documentation/v30b_delta_distillation_results.md +140 -0
- results/dataset_summary.json +91 -0
- results/v30b_summary.json +187 -0
- results/verilogeval_direct_summary.json +7 -0
- results/verilogeval_direct_summary_results.jsonl +156 -0
- scripts/build_v30b_delta_distill_dataset.py +350 -0
- scripts/run_v30b_delta_distill.sh +96 -0
- scripts/score_direct_build.py +82 -0
- tokenizer.json +3 -0
- tokenizer_config.json +37 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
base_model: Qwen/Qwen2.5-Coder-7B-Instruct
|
| 3 |
+
library_name: peft
|
| 4 |
+
pipeline_tag: text-generation
|
| 5 |
+
tags:
|
| 6 |
+
- verilog
|
| 7 |
+
- rtl
|
| 8 |
+
- code-generation
|
| 9 |
+
- qwen2.5-coder
|
| 10 |
+
- lora
|
| 11 |
+
- peft
|
| 12 |
+
- qlora
|
| 13 |
+
- hardware
|
| 14 |
+
- verilog-eval
|
| 15 |
+
license: apache-2.0
|
| 16 |
+
---
|
| 17 |
+
|
| 18 |
+
# Verilog Qwen2.5-Coder 7B v30b Delta-Distilled LoRA
|
| 19 |
+
|
| 20 |
+
`adapter_v30b_delta_distilled_from_v9` is a **single standard PEFT LoRA adapter** for `Qwen/Qwen2.5-Coder-7B-Instruct` focused on Verilog RTL generation.
|
| 21 |
+
|
| 22 |
+
It was trained from the prior `v9` Verilog adapter using delta distillation from a stronger multi-adapter verifier-selector pipeline (`v29`). The goal was to produce a deployable one-adapter model that improves direct VerilogEval performance while preserving broader Verilog behavior.
|
| 23 |
+
|
| 24 |
+
## Important caveat
|
| 25 |
+
|
| 26 |
+
This adapter is **not a clean zero-shot VerilogEval leaderboard model**. It is a targeted/distilled research artifact: some training rows come from v29 selector outputs on VerilogEval prompts that passed compile+simulation. Use the reported VerilogEval score as an experiment result, not as a contamination-free leaderboard claim.
|
| 27 |
+
|
| 28 |
+
For general Verilog usefulness, also see the external paper-style/robust/alt evaluations below.
|
| 29 |
+
|
| 30 |
+
## Results
|
| 31 |
+
|
| 32 |
+
### VerilogEval v2 direct, spec-to-RTL, n=1, temperature 0
|
| 33 |
+
|
| 34 |
+
| Model / system | Compile | Functional pass |
|
| 35 |
+
|---|---:|---:|
|
| 36 |
+
| v9 prior single adapter | — | 67/156 |
|
| 37 |
+
| v29 multi-adapter verifier selector | 150/156 | 84/156 |
|
| 38 |
+
| v30 unified single adapter | 134/156 | 67/156 |
|
| 39 |
+
| **v30b delta-distilled single adapter** | **141/156** | **71/156** |
|
| 40 |
+
|
| 41 |
+
### External/generalization checks
|
| 42 |
+
|
| 43 |
+
| Benchmark | Compile | Functional/task pass |
|
| 44 |
+
|---|---:|---:|
|
| 45 |
+
| Paper-style full | 30/30 | 26/30 task pass; 18/22 functional |
|
| 46 |
+
| Robust suite | 14/15 | 6/10 functional |
|
| 47 |
+
| Alt suite | 7/8 | 3/5 functional |
|
| 48 |
+
|
| 49 |
+
These match the prior v9 baseline on these small external suites, while improving VerilogEval direct from 67 to 71 pass.
|
| 50 |
+
|
| 51 |
+
## Training data mix
|
| 52 |
+
|
| 53 |
+
Dataset builder: `scripts/build_v30b_delta_distill_dataset.py`
|
| 54 |
+
|
| 55 |
+
Unique source counts:
|
| 56 |
+
|
| 57 |
+
- 17 delta wins: v9 failed, v29 selector passed.
|
| 58 |
+
- 84 total v29 selector passing outputs.
|
| 59 |
+
- 67 v9 passing outputs for retention.
|
| 60 |
+
- 382 clean/manual verified rows.
|
| 61 |
+
- 18 external paper-style functional rows.
|
| 62 |
+
- 316 small verified synthetic rows.
|
| 63 |
+
|
| 64 |
+
Default repeat weights:
|
| 65 |
+
|
| 66 |
+
```text
|
| 67 |
+
delta wins: 80x
|
| 68 |
+
all selector pass: 4x
|
| 69 |
+
v9 pass retention: 6x
|
| 70 |
+
clean verified: 2x
|
| 71 |
+
external functional:10x
|
| 72 |
+
synthetic: 1x
|
| 73 |
+
```
|
| 74 |
+
|
| 75 |
+
Training used `--drop-overlength`; rows exceeding the training token limit were dropped instead of truncating Verilog.
|
| 76 |
+
|
| 77 |
+
## Training hyperparameters
|
| 78 |
+
|
| 79 |
+
```text
|
| 80 |
+
base model: Qwen/Qwen2.5-Coder-7B-Instruct
|
| 81 |
+
base adapter: adapter_v9_auto_distilled_direct
|
| 82 |
+
method: QLoRA/LoRA continuation
|
| 83 |
+
LoRA r: 16
|
| 84 |
+
LoRA alpha: 32
|
| 85 |
+
learning rate: 7e-7
|
| 86 |
+
epochs: 0.75
|
| 87 |
+
max length: 2048
|
| 88 |
+
batch size: 1
|
| 89 |
+
grad accum: 4
|
| 90 |
+
warmup steps: 40
|
| 91 |
+
```
|
| 92 |
+
|
| 93 |
+
## Usage
|
| 94 |
+
|
| 95 |
+
```python
|
| 96 |
+
import torch
|
| 97 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig
|
| 98 |
+
from peft import PeftModel
|
| 99 |
+
|
| 100 |
+
base = "Qwen/Qwen2.5-Coder-7B-Instruct"
|
| 101 |
+
adapter = "Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora"
|
| 102 |
+
|
| 103 |
+
bnb = BitsAndBytesConfig(
|
| 104 |
+
load_in_4bit=True,
|
| 105 |
+
bnb_4bit_quant_type="nf4",
|
| 106 |
+
bnb_4bit_compute_dtype=torch.float16,
|
| 107 |
+
bnb_4bit_use_double_quant=True,
|
| 108 |
+
)
|
| 109 |
+
|
| 110 |
+
tok = AutoTokenizer.from_pretrained(base, trust_remote_code=True)
|
| 111 |
+
model = AutoModelForCausalLM.from_pretrained(
|
| 112 |
+
base,
|
| 113 |
+
quantization_config=bnb,
|
| 114 |
+
device_map="auto",
|
| 115 |
+
trust_remote_code=True,
|
| 116 |
+
)
|
| 117 |
+
model = PeftModel.from_pretrained(model, adapter)
|
| 118 |
+
model.eval()
|
| 119 |
+
|
| 120 |
+
prompt = "Write module half_adder(input a, input b, output sum, output carry)."
|
| 121 |
+
messages = [
|
| 122 |
+
{"role": "system", "content": "Return only complete synthesizable Verilog code. No explanation."},
|
| 123 |
+
{"role": "user", "content": prompt},
|
| 124 |
+
]
|
| 125 |
+
text = tok.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
|
| 126 |
+
inputs = tok(text, return_tensors="pt").to(model.device)
|
| 127 |
+
with torch.no_grad():
|
| 128 |
+
out = model.generate(**inputs, max_new_tokens=700, do_sample=False, pad_token_id=tok.eos_token_id)
|
| 129 |
+
print(tok.decode(out[0][inputs["input_ids"].shape[-1]:], skip_special_tokens=True))
|
| 130 |
+
```
|
| 131 |
+
|
| 132 |
+
## Related artifacts
|
| 133 |
+
|
| 134 |
+
- v29 multi-adapter verifier selector pipeline: higher VerilogEval score, but requires multiple adapters plus compile/simulation selection.
|
| 135 |
+
- v30b: this repository, a single deployable PEFT LoRA adapter.
|
| 136 |
+
|
| 137 |
+
## Intended use
|
| 138 |
+
|
| 139 |
+
Research and experimentation with Verilog RTL code generation. Always compile, simulate, lint, and review generated RTL before use.
|
adapter_config.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"alora_invocation_tokens": null,
|
| 3 |
+
"alpha_pattern": {},
|
| 4 |
+
"arrow_config": null,
|
| 5 |
+
"auto_mapping": null,
|
| 6 |
+
"base_model_name_or_path": "Qwen/Qwen2.5-Coder-7B-Instruct",
|
| 7 |
+
"bias": "none",
|
| 8 |
+
"corda_config": null,
|
| 9 |
+
"ensure_weight_tying": false,
|
| 10 |
+
"eva_config": null,
|
| 11 |
+
"exclude_modules": null,
|
| 12 |
+
"fan_in_fan_out": false,
|
| 13 |
+
"inference_mode": true,
|
| 14 |
+
"init_lora_weights": true,
|
| 15 |
+
"layer_replication": null,
|
| 16 |
+
"layers_pattern": null,
|
| 17 |
+
"layers_to_transform": null,
|
| 18 |
+
"loftq_config": {},
|
| 19 |
+
"lora_alpha": 64,
|
| 20 |
+
"lora_bias": false,
|
| 21 |
+
"lora_dropout": 0.05,
|
| 22 |
+
"lora_ga_config": null,
|
| 23 |
+
"megatron_config": null,
|
| 24 |
+
"megatron_core": "megatron.core",
|
| 25 |
+
"modules_to_save": null,
|
| 26 |
+
"peft_type": "LORA",
|
| 27 |
+
"peft_version": "0.19.1",
|
| 28 |
+
"qalora_group_size": 16,
|
| 29 |
+
"r": 32,
|
| 30 |
+
"rank_pattern": {},
|
| 31 |
+
"revision": null,
|
| 32 |
+
"target_modules": [
|
| 33 |
+
"up_proj",
|
| 34 |
+
"k_proj",
|
| 35 |
+
"gate_proj",
|
| 36 |
+
"q_proj",
|
| 37 |
+
"down_proj",
|
| 38 |
+
"v_proj",
|
| 39 |
+
"o_proj"
|
| 40 |
+
],
|
| 41 |
+
"target_parameters": null,
|
| 42 |
+
"task_type": "CAUSAL_LM",
|
| 43 |
+
"trainable_token_indices": null,
|
| 44 |
+
"use_bdlora": null,
|
| 45 |
+
"use_dora": false,
|
| 46 |
+
"use_qalora": false,
|
| 47 |
+
"use_rslora": false
|
| 48 |
+
}
|
adapter_model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a62245ab7f40793ebd6ccd2c516edcff8e3b3dd277a0c26e4fb5baae524b62d2
|
| 3 |
+
size 323014168
|
chat_template.jinja
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{%- if tools %}
|
| 2 |
+
{{- '<|im_start|>system\n' }}
|
| 3 |
+
{%- if messages[0]['role'] == 'system' %}
|
| 4 |
+
{{- messages[0]['content'] }}
|
| 5 |
+
{%- else %}
|
| 6 |
+
{{- 'You are Qwen, created by Alibaba Cloud. You are a helpful assistant.' }}
|
| 7 |
+
{%- endif %}
|
| 8 |
+
{{- "\n\n# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
|
| 9 |
+
{%- for tool in tools %}
|
| 10 |
+
{{- "\n" }}
|
| 11 |
+
{{- tool | tojson }}
|
| 12 |
+
{%- endfor %}
|
| 13 |
+
{{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
|
| 14 |
+
{%- else %}
|
| 15 |
+
{%- if messages[0]['role'] == 'system' %}
|
| 16 |
+
{{- '<|im_start|>system\n' + messages[0]['content'] + '<|im_end|>\n' }}
|
| 17 |
+
{%- else %}
|
| 18 |
+
{{- '<|im_start|>system\nYou are Qwen, created by Alibaba Cloud. You are a helpful assistant.<|im_end|>\n' }}
|
| 19 |
+
{%- endif %}
|
| 20 |
+
{%- endif %}
|
| 21 |
+
{%- for message in messages %}
|
| 22 |
+
{%- if (message.role == "user") or (message.role == "system" and not loop.first) or (message.role == "assistant" and not message.tool_calls) %}
|
| 23 |
+
{{- '<|im_start|>' + message.role + '\n' + message.content + '<|im_end|>' + '\n' }}
|
| 24 |
+
{%- elif message.role == "assistant" %}
|
| 25 |
+
{{- '<|im_start|>' + message.role }}
|
| 26 |
+
{%- if message.content %}
|
| 27 |
+
{{- '\n' + message.content }}
|
| 28 |
+
{%- endif %}
|
| 29 |
+
{%- for tool_call in message.tool_calls %}
|
| 30 |
+
{%- if tool_call.function is defined %}
|
| 31 |
+
{%- set tool_call = tool_call.function %}
|
| 32 |
+
{%- endif %}
|
| 33 |
+
{{- '\n<tool_call>\n{"name": "' }}
|
| 34 |
+
{{- tool_call.name }}
|
| 35 |
+
{{- '", "arguments": ' }}
|
| 36 |
+
{{- tool_call.arguments | tojson }}
|
| 37 |
+
{{- '}\n</tool_call>' }}
|
| 38 |
+
{%- endfor %}
|
| 39 |
+
{{- '<|im_end|>\n' }}
|
| 40 |
+
{%- elif message.role == "tool" %}
|
| 41 |
+
{%- if (loop.index0 == 0) or (messages[loop.index0 - 1].role != "tool") %}
|
| 42 |
+
{{- '<|im_start|>user' }}
|
| 43 |
+
{%- endif %}
|
| 44 |
+
{{- '\n<tool_response>\n' }}
|
| 45 |
+
{{- message.content }}
|
| 46 |
+
{{- '\n</tool_response>' }}
|
| 47 |
+
{%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
|
| 48 |
+
{{- '<|im_end|>\n' }}
|
| 49 |
+
{%- endif %}
|
| 50 |
+
{%- endif %}
|
| 51 |
+
{%- endfor %}
|
| 52 |
+
{%- if add_generation_prompt %}
|
| 53 |
+
{{- '<|im_start|>assistant\n' }}
|
| 54 |
+
{%- endif %}
|
documentation/v30b_delta_distillation_plan.md
ADDED
|
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v30b delta-distillation plan
|
| 2 |
+
|
| 3 |
+
Goal: make one standard PEFT LoRA adapter exceed v9 by focusing on verified delta wins.
|
| 4 |
+
|
| 5 |
+
## Adapter
|
| 6 |
+
|
| 7 |
+
```text
|
| 8 |
+
adapter_v30b_delta_distilled_from_v9
|
| 9 |
+
```
|
| 10 |
+
|
| 11 |
+
## Difference from v30
|
| 12 |
+
|
| 13 |
+
v30 used all v29 selector pass outputs conservatively and matched v9. v30b increases pressure on:
|
| 14 |
+
|
| 15 |
+
```text
|
| 16 |
+
v9 fails + v29 selector passes
|
| 17 |
+
```
|
| 18 |
+
|
| 19 |
+
These delta rows are repeated heavily, while keeping v9/clean/external retention.
|
| 20 |
+
|
| 21 |
+
## Dataset mix
|
| 22 |
+
|
| 23 |
+
Builder:
|
| 24 |
+
|
| 25 |
+
```text
|
| 26 |
+
scripts/build_v30b_delta_distill_dataset.py
|
| 27 |
+
```
|
| 28 |
+
|
| 29 |
+
Default repeats:
|
| 30 |
+
|
| 31 |
+
```text
|
| 32 |
+
delta wins: 80x
|
| 33 |
+
all selector pass: 4x
|
| 34 |
+
v9 pass retention: 6x
|
| 35 |
+
clean verified: 2x
|
| 36 |
+
external functional repair rows: 10x
|
| 37 |
+
small synthetic: 1x
|
| 38 |
+
```
|
| 39 |
+
|
| 40 |
+
## Training
|
| 41 |
+
|
| 42 |
+
Launcher:
|
| 43 |
+
|
| 44 |
+
```text
|
| 45 |
+
scripts/run_v30b_delta_distill.sh
|
| 46 |
+
```
|
| 47 |
+
|
| 48 |
+
Default:
|
| 49 |
+
|
| 50 |
+
```text
|
| 51 |
+
base adapter: adapter_v9_auto_distilled_direct
|
| 52 |
+
epochs: 0.75
|
| 53 |
+
lr: 7e-7
|
| 54 |
+
max_length: 2048
|
| 55 |
+
--drop-overlength
|
| 56 |
+
```
|
| 57 |
+
|
| 58 |
+
## Evaluation
|
| 59 |
+
|
| 60 |
+
- VerilogEval direct
|
| 61 |
+
- paper-style full
|
| 62 |
+
- robust
|
| 63 |
+
- alt
|
| 64 |
+
|
| 65 |
+
## Caveat
|
| 66 |
+
|
| 67 |
+
v30b is one adapter, but uses benchmark-targeted v29 selector outputs. It is a targeted/distilled experiment, not clean zero-shot VerilogEval evidence.
|
documentation/v30b_delta_distillation_results.md
ADDED
|
@@ -0,0 +1,140 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# v30b delta-distilled single-adapter results
|
| 2 |
+
|
| 3 |
+
v30b is the first post-v9 **single standard PEFT LoRA adapter** in this experiment series to improve direct VerilogEval pass count while preserving small external benchmark performance.
|
| 4 |
+
|
| 5 |
+
```text
|
| 6 |
+
adapter_v30b_delta_distilled_from_v9
|
| 7 |
+
```
|
| 8 |
+
|
| 9 |
+
## Motivation
|
| 10 |
+
|
| 11 |
+
The v29 runtime selector reached 84/156 on VerilogEval by generating candidates from v9 plus multiple specialists and selecting with compile+simulation. That is a strong practical pipeline, but it is not a single deployable adapter.
|
| 12 |
+
|
| 13 |
+
v30 attempted broad distillation of v29 into one adapter and matched v9 at 67/156. v30b instead focused training pressure on the delta:
|
| 14 |
+
|
| 15 |
+
```text
|
| 16 |
+
v9 fails + v29 selector passes
|
| 17 |
+
```
|
| 18 |
+
|
| 19 |
+
## Dataset
|
| 20 |
+
|
| 21 |
+
Builder:
|
| 22 |
+
|
| 23 |
+
```text
|
| 24 |
+
scripts/build_v30b_delta_distill_dataset.py
|
| 25 |
+
```
|
| 26 |
+
|
| 27 |
+
Rows:
|
| 28 |
+
|
| 29 |
+
```text
|
| 30 |
+
total rows: 3358
|
| 31 |
+
unique delta wins: 17
|
| 32 |
+
unique selector pass rows: 84
|
| 33 |
+
unique v9 pass retention rows: 67
|
| 34 |
+
unique clean/manual verified rows: 382
|
| 35 |
+
unique external functional rows: 18
|
| 36 |
+
unique synthetic verified rows: 316
|
| 37 |
+
```
|
| 38 |
+
|
| 39 |
+
Repeat weights:
|
| 40 |
+
|
| 41 |
+
```text
|
| 42 |
+
delta wins: 80x
|
| 43 |
+
all selector passes: 4x
|
| 44 |
+
v9 pass retention: 6x
|
| 45 |
+
clean verified: 2x
|
| 46 |
+
external functional: 10x
|
| 47 |
+
synthetic: 1x
|
| 48 |
+
```
|
| 49 |
+
|
| 50 |
+
The 17 delta-win problems were:
|
| 51 |
+
|
| 52 |
+
```text
|
| 53 |
+
Prob018_mux256to1
|
| 54 |
+
Prob028_m2014_q4a
|
| 55 |
+
Prob030_popcount255
|
| 56 |
+
Prob042_vector4
|
| 57 |
+
Prob045_edgedetect2
|
| 58 |
+
Prob050_kmap1
|
| 59 |
+
Prob054_edgedetect
|
| 60 |
+
Prob056_ece241_2013_q7
|
| 61 |
+
Prob060_m2014_q4k
|
| 62 |
+
Prob063_review2015_shiftcount
|
| 63 |
+
Prob075_counter_2bc
|
| 64 |
+
Prob088_ece241_2014_q5b
|
| 65 |
+
Prob097_mux9to1v
|
| 66 |
+
Prob098_circuit7
|
| 67 |
+
Prob121_2014_q3bfsm
|
| 68 |
+
Prob130_circuit5
|
| 69 |
+
Prob138_2012_q2fsm
|
| 70 |
+
```
|
| 71 |
+
|
| 72 |
+
Training used `--drop-overlength`; no rows were truncated.
|
| 73 |
+
|
| 74 |
+
## Training
|
| 75 |
+
|
| 76 |
+
Launcher:
|
| 77 |
+
|
| 78 |
+
```text
|
| 79 |
+
scripts/run_v30b_delta_distill.sh
|
| 80 |
+
```
|
| 81 |
+
|
| 82 |
+
Settings:
|
| 83 |
+
|
| 84 |
+
```text
|
| 85 |
+
base model: Qwen/Qwen2.5-Coder-7B-Instruct
|
| 86 |
+
base adapter: adapter_v9_auto_distilled_direct
|
| 87 |
+
output: adapter_v30b_delta_distilled_from_v9
|
| 88 |
+
epochs: 0.75
|
| 89 |
+
learning rate: 7e-7
|
| 90 |
+
max length: 2048
|
| 91 |
+
LoRA r: 16
|
| 92 |
+
LoRA alpha: 32
|
| 93 |
+
batch size: 1
|
| 94 |
+
grad accum: 4
|
| 95 |
+
warmup steps: 40
|
| 96 |
+
```
|
| 97 |
+
|
| 98 |
+
## Results
|
| 99 |
+
|
| 100 |
+
### VerilogEval v2 direct
|
| 101 |
+
|
| 102 |
+
| Adapter/system | Compile | Pass |
|
| 103 |
+
|---|---:|---:|
|
| 104 |
+
| v9 single adapter | — | 67/156 |
|
| 105 |
+
| v29 multi-adapter selector | 150/156 | 84/156 |
|
| 106 |
+
| v30 unified single adapter | 134/156 | 67/156 |
|
| 107 |
+
| **v30b delta-distilled single adapter** | **141/156** | **71/156** |
|
| 108 |
+
|
| 109 |
+
v30b improves single-adapter pass count by +4 over v9/v30.
|
| 110 |
+
|
| 111 |
+
### External checks
|
| 112 |
+
|
| 113 |
+
| Benchmark | Compile | Functional/task pass |
|
| 114 |
+
|---|---:|---:|
|
| 115 |
+
| Paper-style full | 30/30 | 26/30 task pass; 18/22 functional |
|
| 116 |
+
| Robust | 14/15 | 6/10 functional |
|
| 117 |
+
| Alt | 7/8 | 3/5 functional |
|
| 118 |
+
|
| 119 |
+
These match the v9 baseline on the same external checks, so v30b did not show a regression on these small non-VerilogEval suites.
|
| 120 |
+
|
| 121 |
+
## Interpretation
|
| 122 |
+
|
| 123 |
+
v30b validates the paper-inspired lesson: simple broad SFT/distillation did not beat v9, but **verification-guided delta distillation** can transfer some of the v29 selector's gains into one standard adapter.
|
| 124 |
+
|
| 125 |
+
Still, v30b remains far below the v29 verifier-selector pipeline because a single n=1 generation cannot reproduce multi-candidate search and runtime verification.
|
| 126 |
+
|
| 127 |
+
## Caveat
|
| 128 |
+
|
| 129 |
+
v30b is a single PEFT LoRA adapter, but it is trained with benchmark-targeted v29 selector outputs. Its VerilogEval result should be described as a targeted/distilled experiment, not a clean zero-shot leaderboard claim.
|
| 130 |
+
|
| 131 |
+
## Published artifacts
|
| 132 |
+
|
| 133 |
+
- Hugging Face adapter: `Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora`
|
| 134 |
+
- Main scripts:
|
| 135 |
+
- `scripts/build_v30b_delta_distill_dataset.py`
|
| 136 |
+
- `scripts/run_v30b_delta_distill.sh`
|
| 137 |
+
- Result summary:
|
| 138 |
+
- `results/v30b_delta_distill/v30b_summary.json`
|
| 139 |
+
- `results/v30b_delta_distill/verilogeval_direct_summary.json`
|
| 140 |
+
- `results/v30b_delta_distill/verilogeval_direct_summary_results.jsonl`
|
results/dataset_summary.json
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"output": "data/v30b_delta_distill/v30b_delta_distill_train.jsonl",
|
| 3 |
+
"rows": 3358,
|
| 4 |
+
"unique_delta_wins": 17,
|
| 5 |
+
"unique_selector_pass": 84,
|
| 6 |
+
"unique_v9_pass": 67,
|
| 7 |
+
"unique_clean": 382,
|
| 8 |
+
"unique_external_functional": 18,
|
| 9 |
+
"unique_synthetic": 316,
|
| 10 |
+
"repeats": {
|
| 11 |
+
"delta_repeat": 80,
|
| 12 |
+
"selector_repeat": 4,
|
| 13 |
+
"v9_repeat": 6,
|
| 14 |
+
"clean_repeat": 2,
|
| 15 |
+
"external_repeat": 10,
|
| 16 |
+
"synthetic_repeat": 1
|
| 17 |
+
},
|
| 18 |
+
"by_category_unique": {
|
| 19 |
+
"delta": {
|
| 20 |
+
"comb_vector": 3,
|
| 21 |
+
"other": 1,
|
| 22 |
+
"counter_timer": 3,
|
| 23 |
+
"arith_datapath": 1,
|
| 24 |
+
"seq_shift": 5,
|
| 25 |
+
"case_kmap": 1,
|
| 26 |
+
"fsm_protocol": 3
|
| 27 |
+
},
|
| 28 |
+
"selector": {
|
| 29 |
+
"other": 6,
|
| 30 |
+
"comb_vector": 33,
|
| 31 |
+
"arith_datapath": 12,
|
| 32 |
+
"counter_timer": 11,
|
| 33 |
+
"seq_shift": 10,
|
| 34 |
+
"case_kmap": 2,
|
| 35 |
+
"fsm_protocol": 10
|
| 36 |
+
},
|
| 37 |
+
"v9": {
|
| 38 |
+
"comb_vector": 35,
|
| 39 |
+
"arith_datapath": 11,
|
| 40 |
+
"counter_timer": 9,
|
| 41 |
+
"seq_shift": 4,
|
| 42 |
+
"case_kmap": 1,
|
| 43 |
+
"fsm_protocol": 7
|
| 44 |
+
},
|
| 45 |
+
"clean": {
|
| 46 |
+
"comb_vector": 97,
|
| 47 |
+
"arith_datapath": 42,
|
| 48 |
+
"counter_timer": 91,
|
| 49 |
+
"seq_shift": 49,
|
| 50 |
+
"case_kmap": 19,
|
| 51 |
+
"fsm_protocol": 80,
|
| 52 |
+
"other": 4
|
| 53 |
+
},
|
| 54 |
+
"external": {
|
| 55 |
+
"arith_datapath": 5,
|
| 56 |
+
"comb_vector": 3,
|
| 57 |
+
"case_kmap": 3,
|
| 58 |
+
"seq_shift": 5,
|
| 59 |
+
"other": 1,
|
| 60 |
+
"counter_timer": 1
|
| 61 |
+
},
|
| 62 |
+
"synthetic": {
|
| 63 |
+
"counter_timer": 60,
|
| 64 |
+
"seq_shift": 60,
|
| 65 |
+
"fsm_protocol": 60,
|
| 66 |
+
"comb_vector": 60,
|
| 67 |
+
"arith_datapath": 16,
|
| 68 |
+
"case_kmap": 60
|
| 69 |
+
}
|
| 70 |
+
},
|
| 71 |
+
"delta_problems": [
|
| 72 |
+
"Prob018_mux256to1",
|
| 73 |
+
"Prob028_m2014_q4a",
|
| 74 |
+
"Prob030_popcount255",
|
| 75 |
+
"Prob042_vector4",
|
| 76 |
+
"Prob045_edgedetect2",
|
| 77 |
+
"Prob050_kmap1",
|
| 78 |
+
"Prob054_edgedetect",
|
| 79 |
+
"Prob056_ece241_2013_q7",
|
| 80 |
+
"Prob060_m2014_q4k",
|
| 81 |
+
"Prob063_review2015_shiftcount",
|
| 82 |
+
"Prob075_counter_2bc",
|
| 83 |
+
"Prob088_ece241_2014_q5b",
|
| 84 |
+
"Prob097_mux9to1v",
|
| 85 |
+
"Prob098_circuit7",
|
| 86 |
+
"Prob121_2014_q3bfsm",
|
| 87 |
+
"Prob130_circuit5",
|
| 88 |
+
"Prob138_2012_q2fsm"
|
| 89 |
+
],
|
| 90 |
+
"caveat": "Single-adapter delta distillation from benchmark-targeted v29 selector wins; not clean zero-shot VerilogEval evidence."
|
| 91 |
+
}
|
results/v30b_summary.json
ADDED
|
@@ -0,0 +1,187 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"adapter": "adapter_v30b_delta_distilled_from_v9",
|
| 3 |
+
"hf_repo": "Pablo-Flores-Mollinedo/verilog-qwen2.5-coder-7b-v30b-delta-distilled-lora",
|
| 4 |
+
"verilogeval_direct": {
|
| 5 |
+
"total": 156,
|
| 6 |
+
"compile": 141,
|
| 7 |
+
"passed": 71,
|
| 8 |
+
"compile_pct": 90.38461538461539,
|
| 9 |
+
"pass_pct": 45.51282051282051
|
| 10 |
+
},
|
| 11 |
+
"paper_full": {
|
| 12 |
+
"model": "v30b_delta_paper_full",
|
| 13 |
+
"adapter": "adapter_v30b_delta_distilled_from_v9",
|
| 14 |
+
"suite": "full",
|
| 15 |
+
"tasks": 30,
|
| 16 |
+
"k": 1,
|
| 17 |
+
"compile_any_pass": 30,
|
| 18 |
+
"compile_any_pct": 100.0,
|
| 19 |
+
"task_pass": 26,
|
| 20 |
+
"task_pass_pct": 86.66666666666667,
|
| 21 |
+
"functional_total": 22,
|
| 22 |
+
"functional_pass": 18,
|
| 23 |
+
"functional_pct": 81.81818181818181,
|
| 24 |
+
"by_category": {
|
| 25 |
+
"basic_comb": {
|
| 26 |
+
"total": 7,
|
| 27 |
+
"pass": 7,
|
| 28 |
+
"compile": 7,
|
| 29 |
+
"pass_pct": 100.0,
|
| 30 |
+
"compile_pct": 100.0
|
| 31 |
+
},
|
| 32 |
+
"arith": {
|
| 33 |
+
"total": 3,
|
| 34 |
+
"pass": 3,
|
| 35 |
+
"compile": 3,
|
| 36 |
+
"pass_pct": 100.0,
|
| 37 |
+
"compile_pct": 100.0
|
| 38 |
+
},
|
| 39 |
+
"bit_manip": {
|
| 40 |
+
"total": 4,
|
| 41 |
+
"pass": 4,
|
| 42 |
+
"compile": 4,
|
| 43 |
+
"pass_pct": 100.0,
|
| 44 |
+
"compile_pct": 100.0
|
| 45 |
+
},
|
| 46 |
+
"sequential": {
|
| 47 |
+
"total": 5,
|
| 48 |
+
"pass": 2,
|
| 49 |
+
"compile": 5,
|
| 50 |
+
"pass_pct": 40.0,
|
| 51 |
+
"compile_pct": 100.0
|
| 52 |
+
},
|
| 53 |
+
"fsm": {
|
| 54 |
+
"total": 3,
|
| 55 |
+
"pass": 2,
|
| 56 |
+
"compile": 3,
|
| 57 |
+
"pass_pct": 66.66666666666667,
|
| 58 |
+
"compile_pct": 100.0
|
| 59 |
+
},
|
| 60 |
+
"memory": {
|
| 61 |
+
"total": 3,
|
| 62 |
+
"pass": 3,
|
| 63 |
+
"compile": 3,
|
| 64 |
+
"pass_pct": 100.0,
|
| 65 |
+
"compile_pct": 100.0
|
| 66 |
+
},
|
| 67 |
+
"compile_rtl": {
|
| 68 |
+
"total": 5,
|
| 69 |
+
"pass": 5,
|
| 70 |
+
"compile": 5,
|
| 71 |
+
"pass_pct": 100.0,
|
| 72 |
+
"compile_pct": 100.0
|
| 73 |
+
}
|
| 74 |
+
}
|
| 75 |
+
},
|
| 76 |
+
"robust": {
|
| 77 |
+
"name": "v30b_delta_robust",
|
| 78 |
+
"suite": "robust",
|
| 79 |
+
"total": 15,
|
| 80 |
+
"compile_pass": 14,
|
| 81 |
+
"compile_pct": 93.33333333333333,
|
| 82 |
+
"functional_total": 10,
|
| 83 |
+
"functional_pass": 6,
|
| 84 |
+
"functional_pct": 60.0
|
| 85 |
+
},
|
| 86 |
+
"alt": {
|
| 87 |
+
"name": "v30b_delta_alt",
|
| 88 |
+
"suite": "alt",
|
| 89 |
+
"total": 8,
|
| 90 |
+
"compile_pass": 7,
|
| 91 |
+
"compile_pct": 87.5,
|
| 92 |
+
"functional_total": 5,
|
| 93 |
+
"functional_pass": 3,
|
| 94 |
+
"functional_pct": 60.0
|
| 95 |
+
},
|
| 96 |
+
"dataset": {
|
| 97 |
+
"output": "data/v30b_delta_distill/v30b_delta_distill_train.jsonl",
|
| 98 |
+
"rows": 3358,
|
| 99 |
+
"unique_delta_wins": 17,
|
| 100 |
+
"unique_selector_pass": 84,
|
| 101 |
+
"unique_v9_pass": 67,
|
| 102 |
+
"unique_clean": 382,
|
| 103 |
+
"unique_external_functional": 18,
|
| 104 |
+
"unique_synthetic": 316,
|
| 105 |
+
"repeats": {
|
| 106 |
+
"delta_repeat": 80,
|
| 107 |
+
"selector_repeat": 4,
|
| 108 |
+
"v9_repeat": 6,
|
| 109 |
+
"clean_repeat": 2,
|
| 110 |
+
"external_repeat": 10,
|
| 111 |
+
"synthetic_repeat": 1
|
| 112 |
+
},
|
| 113 |
+
"by_category_unique": {
|
| 114 |
+
"delta": {
|
| 115 |
+
"comb_vector": 3,
|
| 116 |
+
"other": 1,
|
| 117 |
+
"counter_timer": 3,
|
| 118 |
+
"arith_datapath": 1,
|
| 119 |
+
"seq_shift": 5,
|
| 120 |
+
"case_kmap": 1,
|
| 121 |
+
"fsm_protocol": 3
|
| 122 |
+
},
|
| 123 |
+
"selector": {
|
| 124 |
+
"other": 6,
|
| 125 |
+
"comb_vector": 33,
|
| 126 |
+
"arith_datapath": 12,
|
| 127 |
+
"counter_timer": 11,
|
| 128 |
+
"seq_shift": 10,
|
| 129 |
+
"case_kmap": 2,
|
| 130 |
+
"fsm_protocol": 10
|
| 131 |
+
},
|
| 132 |
+
"v9": {
|
| 133 |
+
"comb_vector": 35,
|
| 134 |
+
"arith_datapath": 11,
|
| 135 |
+
"counter_timer": 9,
|
| 136 |
+
"seq_shift": 4,
|
| 137 |
+
"case_kmap": 1,
|
| 138 |
+
"fsm_protocol": 7
|
| 139 |
+
},
|
| 140 |
+
"clean": {
|
| 141 |
+
"comb_vector": 97,
|
| 142 |
+
"arith_datapath": 42,
|
| 143 |
+
"counter_timer": 91,
|
| 144 |
+
"seq_shift": 49,
|
| 145 |
+
"case_kmap": 19,
|
| 146 |
+
"fsm_protocol": 80,
|
| 147 |
+
"other": 4
|
| 148 |
+
},
|
| 149 |
+
"external": {
|
| 150 |
+
"arith_datapath": 5,
|
| 151 |
+
"comb_vector": 3,
|
| 152 |
+
"case_kmap": 3,
|
| 153 |
+
"seq_shift": 5,
|
| 154 |
+
"other": 1,
|
| 155 |
+
"counter_timer": 1
|
| 156 |
+
},
|
| 157 |
+
"synthetic": {
|
| 158 |
+
"counter_timer": 60,
|
| 159 |
+
"seq_shift": 60,
|
| 160 |
+
"fsm_protocol": 60,
|
| 161 |
+
"comb_vector": 60,
|
| 162 |
+
"arith_datapath": 16,
|
| 163 |
+
"case_kmap": 60
|
| 164 |
+
}
|
| 165 |
+
},
|
| 166 |
+
"delta_problems": [
|
| 167 |
+
"Prob018_mux256to1",
|
| 168 |
+
"Prob028_m2014_q4a",
|
| 169 |
+
"Prob030_popcount255",
|
| 170 |
+
"Prob042_vector4",
|
| 171 |
+
"Prob045_edgedetect2",
|
| 172 |
+
"Prob050_kmap1",
|
| 173 |
+
"Prob054_edgedetect",
|
| 174 |
+
"Prob056_ece241_2013_q7",
|
| 175 |
+
"Prob060_m2014_q4k",
|
| 176 |
+
"Prob063_review2015_shiftcount",
|
| 177 |
+
"Prob075_counter_2bc",
|
| 178 |
+
"Prob088_ece241_2014_q5b",
|
| 179 |
+
"Prob097_mux9to1v",
|
| 180 |
+
"Prob098_circuit7",
|
| 181 |
+
"Prob121_2014_q3bfsm",
|
| 182 |
+
"Prob130_circuit5",
|
| 183 |
+
"Prob138_2012_q2fsm"
|
| 184 |
+
],
|
| 185 |
+
"caveat": "Single-adapter delta distillation from benchmark-targeted v29 selector wins; not clean zero-shot VerilogEval evidence."
|
| 186 |
+
}
|
| 187 |
+
}
|
results/verilogeval_direct_summary.json
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"total": 156,
|
| 3 |
+
"compile": 141,
|
| 4 |
+
"passed": 71,
|
| 5 |
+
"compile_pct": 90.38461538461539,
|
| 6 |
+
"pass_pct": 45.51282051282051
|
| 7 |
+
}
|
results/verilogeval_direct_summary_results.jsonl
ADDED
|
@@ -0,0 +1,156 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"problem": "Prob001_zero", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'zero' has no mismatches.\nHint: Total mismatched samples is 0 out of 20 samples\n\nSimulation finished at 102 ps\nMismatches: 0 in 20 samples\n"}
|
| 2 |
+
{"problem": "Prob002_m2014_q4i", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 3 |
+
{"problem": "Prob003_step_one", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'one' has no mismatches.\nHint: Total mismatched samples is 0 out of 20 samples\n\nSimulation finished at 102 ps\nMismatches: 0 in 20 samples\n"}
|
| 4 |
+
{"problem": "Prob004_vector2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 110 samples\n\nSimulation finished at 550 ps\nMismatches: 0 in 110 samples\n"}
|
| 5 |
+
{"problem": "Prob005_notgate", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 239 samples\n\nSimulation finished at 1196 ps\nMismatches: 0 in 239 samples\n"}
|
| 6 |
+
{"problem": "Prob006_vectorr", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 218 samples\n\nSimulation finished at 1090 ps\nMismatches: 0 in 218 samples\n"}
|
| 7 |
+
{"problem": "Prob007_wire", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 120 samples\n\nSimulation finished at 601 ps\nMismatches: 0 in 120 samples\n"}
|
| 8 |
+
{"problem": "Prob008_m2014_q4h", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 9 |
+
{"problem": "Prob009_popcount3", "compile": false, "passed": false, "log": "dut.sv:12: warning: Numeric constant truncated to 3 bits.\ndut.sv:13: warning: Numeric constant truncated to 3 bits.\ndut.sv:14: syntax error\ndut.sv:14: error: Incomprehensible case expression.\ndut.sv:15: syntax error\ndut.sv:15: error: Incomprehensible case expression.\ndut.sv:16: syntax error\ndut.sv:16: error: Incomprehensible case expression.\ndut.sv:17: syntax error\ndut.sv:17: error: Incomprehensible case expression.\ndut.sv:18: syntax error\ndut.sv:18: error: Incomprehensible case expression.\ndut.sv:19: syntax error\ndut.sv:19: warning: Numeric constant truncated to 2 bits.\ndut.sv:19: error: Incomprehensible case expression.\n"}
|
| 10 |
+
{"problem": "Prob010_mt2015_q4a", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has no mismatches.\nHint: Total mismatched samples is 0 out of 202 samples\n\nSimulation finished at 1011 ps\nMismatches: 0 in 202 samples\n"}
|
| 11 |
+
{"problem": "Prob011_norgate", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 0 in 219 samples\n"}
|
| 12 |
+
{"problem": "Prob012_xnorgate", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 0 in 219 samples\n"}
|
| 13 |
+
{"problem": "Prob013_m2014_q4e", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 14 |
+
{"problem": "Prob014_andgate", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 0 in 219 samples\n"}
|
| 15 |
+
{"problem": "Prob015_vector1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_hi' has no mismatches.\nHint: Output 'out_lo' has no mismatches.\nHint: Total mismatched samples is 0 out of 218 samples\n\nSimulation finished at 1090 ps\nMismatches: 0 in 218 samples\n"}
|
| 16 |
+
{"problem": "Prob016_m2014_q4j", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'sum' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 17 |
+
{"problem": "Prob017_mux2to1v", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 114 samples\n\nSimulation finished at 570 ps\nMismatches: 0 in 114 samples\n"}
|
| 18 |
+
{"problem": "Prob018_mux256to1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 2000 samples\n\nSimulation finished at 10000 ps\nMismatches: 0 in 2000 samples\n"}
|
| 19 |
+
{"problem": "Prob019_m2014_q4f", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 27 mismatches. First mismatch occurred at time 45.\nHint: Total mismatched samples is 27 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 27 in 100 samples\n"}
|
| 20 |
+
{"problem": "Prob020_mt2015_eq2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has no mismatches.\nHint: Total mismatched samples is 0 out of 2000 samples\n\nSimulation finished at 10001 ps\nMismatches: 0 in 2000 samples\n"}
|
| 21 |
+
{"problem": "Prob021_mux256to1v", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 1943 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 1943 out of 2000 samples\n\nSimulation finished at 10000 ps\nMismatches: 1943 in 2000 samples\n"}
|
| 22 |
+
{"problem": "Prob022_mux2to1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 122 samples\n\nSimulation finished at 610 ps\nMismatches: 0 in 122 samples\n"}
|
| 23 |
+
{"problem": "Prob023_vector100r", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 200 samples\n\nSimulation finished at 1000 ps\nMismatches: 0 in 200 samples\n"}
|
| 24 |
+
{"problem": "Prob024_hadd", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'sum' has no mismatches.\nHint: Output 'cout' has no mismatches.\nHint: Total mismatched samples is 0 out of 200 samples\n\nSimulation finished at 1000 ps\nMismatches: 0 in 200 samples\n"}
|
| 25 |
+
{"problem": "Prob025_reduction", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'parity' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 500 ps\nMismatches: 0 in 100 samples\n"}
|
| 26 |
+
{"problem": "Prob026_alwaysblock1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_assign' has no mismatches.\nHint: Output 'out_alwaysblock' has no mismatches.\nHint: Total mismatched samples is 0 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 0 in 219 samples\n"}
|
| 27 |
+
{"problem": "Prob027_fadd", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'cout' has no mismatches.\nHint: Output 'sum' has no mismatches.\nHint: Total mismatched samples is 0 out of 214 samples\n\nSimulation finished at 1070 ps\nMismatches: 0 in 214 samples\n"}
|
| 28 |
+
{"problem": "Prob028_m2014_q4a", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 29 |
+
{"problem": "Prob029_m2014_q4g", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 51 mismatches. First mismatch occurred at time 25.\nHint: Total mismatched samples is 51 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 51 in 100 samples\n"}
|
| 30 |
+
{"problem": "Prob030_popcount255", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 215 samples\n\nSimulation finished at 1076 ps\nMismatches: 0 in 215 samples\n"}
|
| 31 |
+
{"problem": "Prob031_dff", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 118 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 118 out of 121 samples\n\nSimulation finished at 605 ps\nMismatches: 118 in 121 samples\n"}
|
| 32 |
+
{"problem": "Prob032_vector0", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'outv' has no mismatches.\nHint: Output 'o2' has no mismatches.\nHint: Output 'o1' has no mismatches.\nHint: Output 'o0' has no mismatches.\nHint: Total mismatched samples is 0 out of 21 samples\n\nSimulation finished at 107 ps\nMismatches: 0 in 21 samples\n"}
|
| 33 |
+
{"problem": "Prob033_ece241_2014_q1c", "compile": false, "passed": false, "log": "dut.sv:5: error: overflow is not a valid l-value in tb.top_module1.\ndut.sv:1: : overflow is declared here as wire.\n1 error(s) during elaboration.\n"}
|
| 34 |
+
{"problem": "Prob034_dff8", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 1 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 1 out of 41 samples\n\nSimulation finished at 206 ps\nMismatches: 1 in 41 samples\n"}
|
| 35 |
+
{"problem": "Prob035_count1to10", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 439 samples\n\nSimulation finished at 2196 ps\nMismatches: 0 in 439 samples\n"}
|
| 36 |
+
{"problem": "Prob036_ringer", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'ringer' has no mismatches.\nHint: Output 'motor' has no mismatches.\nHint: Total mismatched samples is 0 out of 19 samples\n\nSimulation finished at 97 ps\nMismatches: 0 in 19 samples\n"}
|
| 37 |
+
{"problem": "Prob037_review2015_count1k", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 8027 samples\n\nSimulation finished at 40136 ps\nMismatches: 0 in 8027 samples\n"}
|
| 38 |
+
{"problem": "Prob038_count15", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 421 samples\n\nSimulation finished at 2106 ps\nMismatches: 0 in 421 samples\n"}
|
| 39 |
+
{"problem": "Prob039_always_if", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_assign' has no mismatches.\nHint: Output 'out_always' has no mismatches.\nHint: Total mismatched samples is 0 out of 114 samples\n\nSimulation finished at 570 ps\nMismatches: 0 in 114 samples\n"}
|
| 40 |
+
{"problem": "Prob040_count10", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 439 samples\n\nSimulation finished at 2196 ps\nMismatches: 0 in 439 samples\n"}
|
| 41 |
+
{"problem": "Prob041_dff8r", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 432 samples\n\nSimulation finished at 2161 ps\nMismatches: 0 in 432 samples\n"}
|
| 42 |
+
{"problem": "Prob042_vector4", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 500 ps\nMismatches: 0 in 100 samples\n"}
|
| 43 |
+
{"problem": "Prob043_vector5", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 500 ps\nMismatches: 0 in 100 samples\n"}
|
| 44 |
+
{"problem": "Prob044_vectorgates", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_or_bitwise' has no mismatches.\nHint: Output 'out_or_logical' has no mismatches.\nHint: Output 'out_not' has no mismatches.\nHint: Total mismatched samples is 0 out of 261 samples\n\nSimulation finished at 1306 ps\nMismatches: 0 in 261 samples\n"}
|
| 45 |
+
{"problem": "Prob045_edgedetect2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'anyedge' has 146 mismatches. First mismatch occurred at time 170.\nHint: Total mismatched samples is 146 out of 228 samples\n\nSimulation finished at 1140 ps\nMismatches: 146 in 228 samples\n"}
|
| 46 |
+
{"problem": "Prob046_dff8p", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 408 mismatches. First mismatch occurred at time 45.\nHint: Total mismatched samples is 408 out of 436 samples\n\nSimulation finished at 2181 ps\nMismatches: 408 in 436 samples\n"}
|
| 47 |
+
{"problem": "Prob047_dff8ar", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset should be asynchronous, but doesn't appear to be.\nHint: Output 'q' has 44 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 44 out of 436 samples\n\nSimulation finished at 2181 ps\nMismatches: 44 in 436 samples\n"}
|
| 48 |
+
{"problem": "Prob048_m2014_q4c", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 0 in 100 samples\n"}
|
| 49 |
+
{"problem": "Prob049_m2014_q4b", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 17 mismatches. First mismatch occurred at time 15.\nHint: Total mismatched samples is 17 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 17 in 100 samples\n"}
|
| 50 |
+
{"problem": "Prob050_kmap1", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 90 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 90 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 90 in 219 samples\n"}
|
| 51 |
+
{"problem": "Prob051_gates4", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_and' has no mismatches.\nHint: Output 'out_or' has no mismatches.\nHint: Output 'out_xor' has no mismatches.\nHint: Total mismatched samples is 0 out of 234 samples\n\nSimulation finished at 1170 ps\nMismatches: 0 in 234 samples\n"}
|
| 52 |
+
{"problem": "Prob052_gates100", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_and' has no mismatches.\nHint: Output 'out_or' has no mismatches.\nHint: Output 'out_xor' has no mismatches.\nHint: Total mismatched samples is 0 out of 433 samples\n\nSimulation finished at 2166 ps\nMismatches: 0 in 433 samples\n"}
|
| 53 |
+
{"problem": "Prob053_m2014_q4d", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 1 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 1 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 1 in 100 samples\n"}
|
| 54 |
+
{"problem": "Prob054_edgedetect", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'pedge' has no mismatches.\nHint: Total mismatched samples is 0 out of 227 samples\n\nSimulation finished at 1135 ps\nMismatches: 0 in 227 samples\n"}
|
| 55 |
+
{"problem": "Prob055_conditional", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'min' has no mismatches.\nHint: Total mismatched samples is 0 out of 112 samples\n\nSimulation finished at 560 ps\nMismatches: 0 in 112 samples\n"}
|
| 56 |
+
{"problem": "Prob056_ece241_2013_q7", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Q' has no mismatches.\nHint: Total mismatched samples is 0 out of 422 samples\n\nSimulation finished at 2110 ps\nMismatches: 0 in 422 samples\n"}
|
| 57 |
+
{"problem": "Prob057_kmap2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 123 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 123 out of 232 samples\n\nSimulation finished at 1161 ps\nMismatches: 123 in 232 samples\n"}
|
| 58 |
+
{"problem": "Prob058_alwaysblock2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_assign' has no mismatches.\nHint: Output 'out_always_comb' has no mismatches.\nHint: Output 'out_always_ff' has no mismatches.\nHint: Total mismatched samples is 0 out of 219 samples\n\nSimulation finished at 1096 ps\nMismatches: 0 in 219 samples\n"}
|
| 59 |
+
{"problem": "Prob059_wire4", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'w' has no mismatches.\nHint: Output 'x' has no mismatches.\nHint: Output 'y' has no mismatches.\nHint: Output 'z' has no mismatches.\nHint: Total mismatched samples is 0 out of 218 samples\n\nSimulation finished at 1090 ps\nMismatches: 0 in 218 samples\n"}
|
| 60 |
+
{"problem": "Prob060_m2014_q4k", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 299 samples\n\nSimulation finished at 1496 ps\nMismatches: 0 in 299 samples\n"}
|
| 61 |
+
{"problem": "Prob061_2014_q4a", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Q' has no mismatches.\nHint: Total mismatched samples is 0 out of 200 samples\n\nSimulation finished at 1001 ps\nMismatches: 0 in 200 samples\n"}
|
| 62 |
+
{"problem": "Prob062_bugs_mux2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 110 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 110 out of 114 samples\n\nSimulation finished at 570 ps\nMismatches: 110 in 114 samples\n"}
|
| 63 |
+
{"problem": "Prob063_review2015_shiftcount", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 2071 samples\n\nSimulation finished at 10356 ps\nMismatches: 0 in 2071 samples\n"}
|
| 64 |
+
{"problem": "Prob064_vector3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'w' has 100 mismatches. First mismatch occurred at time 130.\nHint: Output 'x' has 101 mismatches. First mismatch occurred at time 130.\nHint: Output 'y' has 115 mismatches. First mismatch occurred at time 60.\nHint: Output 'z' has 126 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 126 out of 126 samples\n\nSimulation finished at 630 ps\nMismatches: 126 in 126 samples\n"}
|
| 65 |
+
{"problem": "Prob065_7420", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'p1y' has no mismatches.\nHint: Output 'p2y' has no mismatches.\nHint: Total mismatched samples is 0 out of 239 samples\n\nSimulation finished at 1196 ps\nMismatches: 0 in 239 samples\n"}
|
| 66 |
+
{"problem": "Prob066_edgecapture", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 225 mismatches. First mismatch occurred at time 100.\nHint: Total mismatched samples is 225 out of 266 samples\n\nSimulation finished at 1330 ps\nMismatches: 225 in 266 samples\n"}
|
| 67 |
+
{"problem": "Prob067_countslow", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 499 samples\n\nSimulation finished at 2496 ps\nMismatches: 0 in 499 samples\n"}
|
| 68 |
+
{"problem": "Prob068_countbcd", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'ena' has 39634 mismatches. First mismatch occurred at time 160.\nHint: Output 'q' has 39756 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 39774 out of 39805 samples\n\nSimulation finished at 199026 ps\nMismatches: 39774 in 39805 samples\n"}
|
| 69 |
+
{"problem": "Prob069_truthtable1", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'f' has 50 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 50 out of 58 samples\n\nSimulation finished at 290 ps\nMismatches: 50 in 58 samples\n"}
|
| 70 |
+
{"problem": "Prob070_ece241_2013_q2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_sop' has 36 mismatches. First mismatch occurred at time 20.\nHint: Output 'out_pos' has 27 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 44 out of 107 samples\n\nSimulation finished at 535 ps\nMismatches: 44 in 107 samples\n"}
|
| 71 |
+
{"problem": "Prob071_always_casez", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'pos' has 1 mismatches. First mismatch occurred at time 1415.\nHint: Total mismatched samples is 1 out of 346 samples\n\nSimulation finished at 1730 ps\nMismatches: 1 in 346 samples\n"}
|
| 72 |
+
{"problem": "Prob072_thermostat", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'heater' has no mismatches.\nHint: Output 'aircon' has no mismatches.\nHint: Output 'fan' has no mismatches.\nHint: Total mismatched samples is 0 out of 248 samples\n\nSimulation finished at 1241 ps\nMismatches: 0 in 248 samples\n"}
|
| 73 |
+
{"problem": "Prob073_dff16e", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 443 samples\n\nSimulation finished at 2216 ps\nMismatches: 0 in 443 samples\n"}
|
| 74 |
+
{"problem": "Prob074_ece241_2014_q4", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 45 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 45 out of 118 samples\n\nSimulation finished at 590 ps\nMismatches: 45 in 118 samples\n"}
|
| 75 |
+
{"problem": "Prob075_counter_2bc", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'state' has no mismatches.\nHint: Total mismatched samples is 0 out of 1051 samples\n\nSimulation finished at 5256 ps\nMismatches: 0 in 1051 samples\n"}
|
| 76 |
+
{"problem": "Prob076_always_case", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 118 samples\n\nSimulation finished at 590 ps\nMismatches: 0 in 118 samples\n"}
|
| 77 |
+
{"problem": "Prob077_wire_decl", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Output 'out_n' has no mismatches.\nHint: Total mismatched samples is 0 out of 122 samples\n\nSimulation finished at 611 ps\nMismatches: 0 in 122 samples\n"}
|
| 78 |
+
{"problem": "Prob078_dualedge", "compile": false, "passed": false, "log": "dut.sv:2: syntax error\ndut.sv:2: Syntax in assignment statement l-value.\n"}
|
| 79 |
+
{"problem": "Prob079_fsm3onehot", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'next_state' has 141 mismatches. First mismatch occurred at time 10.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 141 out of 200 samples\n\nSimulation finished at 1001 ps\nMismatches: 141 in 200 samples\n"}
|
| 80 |
+
{"problem": "Prob080_timer", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'tc' has no mismatches.\nHint: Total mismatched samples is 0 out of 7127 samples\n\nSimulation finished at 35636 ps\nMismatches: 0 in 7127 samples\n"}
|
| 81 |
+
{"problem": "Prob081_7458", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'p1y' has no mismatches.\nHint: Output 'p2y' has no mismatches.\nHint: Total mismatched samples is 0 out of 439 samples\n\nSimulation finished at 2196 ps\nMismatches: 0 in 439 samples\n"}
|
| 82 |
+
{"problem": "Prob082_lfsr32", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nTIMEOUT\nHint: Output 'q' has 199953 mismatches. First mismatch occurred at time 190.\nHint: Total mismatched samples is 199953 out of 200000 samples\n\nSimulation finished at 1000000 ps\nMismatches: 199953 in 200000 samples\n"}
|
| 83 |
+
{"problem": "Prob083_mt2015_q4b", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has no mismatches.\nHint: Total mismatched samples is 0 out of 110 samples\n\nSimulation finished at 551 ps\nMismatches: 0 in 110 samples\n"}
|
| 84 |
+
{"problem": "Prob084_ece241_2013_q12", "compile": false, "passed": false, "log": "dut.sv:9: syntax error\ndut.sv:6: error: syntax error in continuous assignment\n"}
|
| 85 |
+
{"problem": "Prob085_shift4", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset should be asynchronous, but doesn't appear to be.\nHint: Output 'q' has 73 mismatches. First mismatch occurred at time 40.\nHint: Total mismatched samples is 73 out of 427 samples\n\nSimulation finished at 2136 ps\nMismatches: 73 in 427 samples\n"}
|
| 86 |
+
{"problem": "Prob086_lfsr5", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 4266 mismatches. First mismatch occurred at time 40.\nHint: Total mismatched samples is 4266 out of 4443 samples\n\nSimulation finished at 22216 ps\nMismatches: 4266 in 4443 samples\n"}
|
| 87 |
+
{"problem": "Prob087_gates", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_and' has no mismatches.\nHint: Output 'out_or' has no mismatches.\nHint: Output 'out_xor' has no mismatches.\nHint: Output 'out_nand' has no mismatches.\nHint: Output 'out_nor' has no mismatches.\nHint: Output 'out_xnor' has no mismatches.\nHint: Output 'out_anotb' has no mismatches.\nHint: Total mismatched samples is 0 out of 210 samples\n\nSimulation finished at 1050 ps\nMismatches: 0 in 210 samples\n"}
|
| 88 |
+
{"problem": "Prob088_ece241_2014_q5b", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset doesn't seem to be working.\nHint: Output 'z' has 436 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 436 out of 436 samples\n\nSimulation finished at 2180 ps\nMismatches: 436 in 436 samples\n"}
|
| 89 |
+
{"problem": "Prob089_ece241_2014_q5a", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 393 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 393 out of 436 samples\n\nSimulation finished at 2180 ps\nMismatches: 393 in 436 samples\n"}
|
| 90 |
+
{"problem": "Prob090_circuit1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 120 samples\n\nSimulation finished at 600 ps\nMismatches: 0 in 120 samples\n"}
|
| 91 |
+
{"problem": "Prob091_2012_q2b", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Y1' has 238 mismatches. First mismatch occurred at time 15.\nHint: Output 'Y3' has 325 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 443 out of 600 samples\n\nSimulation finished at 3001 ps\nMismatches: 443 in 600 samples\n"}
|
| 92 |
+
{"problem": "Prob092_gatesv100", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_both' has no mismatches.\nHint: Output 'out_any' has 201 mismatches. First mismatch occurred at time 5.\nHint: Output 'out_different' has no mismatches.\nHint: Total mismatched samples is 201 out of 201 samples\n\nSimulation finished at 1006 ps\nMismatches: 201 in 201 samples\n"}
|
| 93 |
+
{"problem": "Prob093_ece241_2014_q3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'mux_in' has 60 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 60 out of 60 samples\n\nSimulation finished at 300 ps\nMismatches: 60 in 60 samples\n"}
|
| 94 |
+
{"problem": "Prob094_gatesv", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_both' has 116 mismatches. First mismatch occurred at time 5.\nHint: Output 'out_any' has 109 mismatches. First mismatch occurred at time 5.\nHint: Output 'out_different' has 160 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 172 out of 213 samples\n\nSimulation finished at 1066 ps\nMismatches: 172 in 213 samples\n"}
|
| 95 |
+
{"problem": "Prob095_review2015_fsmshift", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'shift_ena' has no mismatches.\nHint: Total mismatched samples is 0 out of 200 samples\n\nSimulation finished at 1001 ps\nMismatches: 0 in 200 samples\n"}
|
| 96 |
+
{"problem": "Prob096_review2015_fsmseq", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'start_shifting' has 306 mismatches. First mismatch occurred at time 50.\nHint: Total mismatched samples is 306 out of 643 samples\n\nSimulation finished at 3216 ps\nMismatches: 306 in 643 samples\n"}
|
| 97 |
+
{"problem": "Prob097_mux9to1v", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 220 samples\n\nSimulation finished at 1100 ps\nMismatches: 0 in 220 samples\n"}
|
| 98 |
+
{"problem": "Prob098_circuit7", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 120 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 120 out of 123 samples\n\nSimulation finished at 615 ps\nMismatches: 120 in 123 samples\n"}
|
| 99 |
+
{"problem": "Prob099_m2014_q6c", "compile": false, "passed": false, "log": "test.sv:71: error: port ``Y2'' is not a port of good1.\ntest.sv:71: error: port ``Y4'' is not a port of good1.\ntest.sv:77: error: port ``Y2'' is not a port of top_module1.\ntest.sv:77: error: port ``Y4'' is not a port of top_module1.\n4 error(s) during elaboration.\n"}
|
| 100 |
+
{"problem": "Prob100_fsm3comb", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'next_state' has 70 mismatches. First mismatch occurred at time 10.\nHint: Output 'out' has 14 mismatches. First mismatch occurred at time 40.\nHint: Total mismatched samples is 70 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 70 in 100 samples\n"}
|
| 101 |
+
{"problem": "Prob101_circuit4", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 53 mismatches. First mismatch occurred at time 25.\nHint: Total mismatched samples is 53 out of 121 samples\n\nSimulation finished at 605 ps\nMismatches: 53 in 121 samples\n"}
|
| 102 |
+
{"problem": "Prob102_circuit3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 64 mismatches. First mismatch occurred at time 25.\nHint: Total mismatched samples is 64 out of 121 samples\n\nSimulation finished at 605 ps\nMismatches: 64 in 121 samples\n"}
|
| 103 |
+
{"problem": "Prob103_circuit2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 121 samples\n\nSimulation finished at 605 ps\nMismatches: 0 in 121 samples\n"}
|
| 104 |
+
{"problem": "Prob104_mt2015_muxdff", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Q' has 1 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 1 out of 199 samples\n\nSimulation finished at 996 ps\nMismatches: 1 in 199 samples\n"}
|
| 105 |
+
{"problem": "Prob105_rotate100", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 3292 mismatches. First mismatch occurred at time 60.\nHint: Total mismatched samples is 3292 out of 4005 samples\n\nSimulation finished at 20026 ps\nMismatches: 3292 in 4005 samples\n"}
|
| 106 |
+
{"problem": "Prob106_always_nolatches", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'left' has no mismatches.\nHint: Output 'down' has no mismatches.\nHint: Output 'right' has no mismatches.\nHint: Output 'up' has no mismatches.\nHint: Total mismatched samples is 0 out of 30020 samples\n\nSimulation finished at 150100 ps\nMismatches: 0 in 30020 samples\n"}
|
| 107 |
+
{"problem": "Prob107_fsm1s", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 137 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 137 out of 230 samples\n\nSimulation finished at 1151 ps\nMismatches: 137 in 230 samples\n"}
|
| 108 |
+
{"problem": "Prob108_rule90", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 6022 mismatches. First mismatch occurred at time 50.\nHint: Total mismatched samples is 6022 out of 7121 samples\n\nSimulation finished at 35606 ps\nMismatches: 6022 in 7121 samples\n"}
|
| 109 |
+
{"problem": "Prob109_fsm1", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 228 samples\n\nSimulation finished at 1141 ps\nMismatches: 0 in 228 samples\n"}
|
| 110 |
+
{"problem": "Prob110_fsm2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 241 samples\n\nSimulation finished at 1206 ps\nMismatches: 0 in 241 samples\n"}
|
| 111 |
+
{"problem": "Prob111_fsm2s", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Total mismatched samples is 0 out of 241 samples\n\nSimulation finished at 1206 ps\nMismatches: 0 in 241 samples\n"}
|
| 112 |
+
{"problem": "Prob112_always_case2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'pos' has 61 mismatches. First mismatch occurred at time 90.\nHint: Total mismatched samples is 61 out of 94 samples\n\nSimulation finished at 470 ps\nMismatches: 61 in 94 samples\n"}
|
| 113 |
+
{"problem": "Prob113_2012_q1g", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'f' has 30 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 30 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 30 in 100 samples\n"}
|
| 114 |
+
{"problem": "Prob114_bugs_case", "compile": false, "passed": false, "log": "dut.sv:4: syntax error\ndut.sv:5: error: Incomprehensible case expression.\ndut.sv:5: syntax error\ndut.sv:6: error: Incomprehensible case expression.\ndut.sv:6: syntax error\ndut.sv:7: error: Incomprehensible case expression.\ndut.sv:7: syntax error\ndut.sv:8: error: Incomprehensible case expression.\ndut.sv:8: syntax error\ndut.sv:9: error: Incomprehensible case expression.\ndut.sv:9: syntax error\ndut.sv:10: error: Incomprehensible case expression.\ndut.sv:10: syntax error\ndut.sv:11: error: Incomprehensible case expression.\ndut.sv:11: syntax error\ndut.sv:12: error: Incomprehensible case expression.\ndut.sv:12: syntax error\ndut.sv:13: error: Incomprehensible case expression.\ndut.sv:13: syntax error\ndut.sv:14: error: Incomprehensible case expression.\n"}
|
| 115 |
+
{"problem": "Prob115_shift18", "compile": false, "passed": false, "log": "dut.sv:8: warning: extra digits given for sized binary constant.\ndut.sv:8: syntax error\ndut.sv:8: error: malformed statement\n"}
|
| 116 |
+
{"problem": "Prob116_m2014_q3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'f' has 40 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 40 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 40 in 100 samples\n"}
|
| 117 |
+
{"problem": "Prob117_circuit9", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 244 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 244 out of 245 samples\n\nSimulation finished at 1225 ps\nMismatches: 244 in 245 samples\n"}
|
| 118 |
+
{"problem": "Prob118_history_shift", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'predict_history' has 980 mismatches. First mismatch occurred at time 220.\nHint: Total mismatched samples is 980 out of 2055 samples\n\nSimulation finished at 10276 ps\nMismatches: 980 in 2055 samples\n"}
|
| 119 |
+
{"problem": "Prob119_fsm3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 56 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 56 out of 230 samples\n\nSimulation finished at 1151 ps\nMismatches: 56 in 230 samples\n"}
|
| 120 |
+
{"problem": "Prob120_fsm3s", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 56 mismatches. First mismatch occurred at time 40.\nHint: Total mismatched samples is 56 out of 230 samples\n\nSimulation finished at 1151 ps\nMismatches: 56 in 230 samples\n"}
|
| 121 |
+
{"problem": "Prob121_2014_q3bfsm", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 516 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 516 out of 1006 samples\n\nSimulation finished at 5031 ps\nMismatches: 516 in 1006 samples\n"}
|
| 122 |
+
{"problem": "Prob122_kmap4", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 142 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 142 out of 232 samples\n\nSimulation finished at 1161 ps\nMismatches: 142 in 232 samples\n"}
|
| 123 |
+
{"problem": "Prob123_bugs_addsubz", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has no mismatches.\nHint: Output 'result_is_zero' has no mismatches.\nHint: Total mismatched samples is 0 out of 118 samples\n\nSimulation finished at 590 ps\nMismatches: 0 in 118 samples\n"}
|
| 124 |
+
{"problem": "Prob124_rule110", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 6220 mismatches. First mismatch occurred at time 40.\nHint: Total mismatched samples is 6220 out of 6283 samples\n\nSimulation finished at 31416 ps\nMismatches: 6220 in 6283 samples\n"}
|
| 125 |
+
{"problem": "Prob125_kmap3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out' has 124 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 124 out of 232 samples\n\nSimulation finished at 1161 ps\nMismatches: 124 in 232 samples\n"}
|
| 126 |
+
{"problem": "Prob126_circuit6", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has no mismatches.\nHint: Total mismatched samples is 0 out of 113 samples\n\nSimulation finished at 565 ps\nMismatches: 0 in 113 samples\n"}
|
| 127 |
+
{"problem": "Prob127_lemmings1", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset doesn't seem to be working.\nHint: Output 'walk_left' has 133 mismatches. First mismatch occurred at time 5.\nHint: Output 'walk_right' has 137 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 205 out of 229 samples\n\nSimulation finished at 1146 ps\nMismatches: 205 in 229 samples\n"}
|
| 128 |
+
{"problem": "Prob128_fsm_ps2", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'done' has no mismatches.\nHint: Total mismatched samples is 0 out of 400 samples\n\nSimulation finished at 2001 ps\nMismatches: 0 in 400 samples\n"}
|
| 129 |
+
{"problem": "Prob129_ece241_2013_q8", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 287 mismatches. First mismatch occurred at time 5.\nHint: Total mismatched samples is 287 out of 440 samples\n\nSimulation finished at 2200 ps\nMismatches: 287 in 440 samples\n"}
|
| 130 |
+
{"problem": "Prob130_circuit5", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 40 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 40 out of 141 samples\n\nSimulation finished at 705 ps\nMismatches: 40 in 141 samples\n"}
|
| 131 |
+
{"problem": "Prob131_mt2015_q4", "compile": false, "passed": false, "log": "test.sv:68: error: Unknown module type: TopModule\n2 error(s) during elaboration.\n*** These modules were missing:\n TopModule referenced 1 times.\n***\n"}
|
| 132 |
+
{"problem": "Prob132_always_if2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'shut_off_computer' has no mismatches.\nHint: Output 'keep_driving' has 41 mismatches. First mismatch occurred at time 30.\nHint: Total mismatched samples is 41 out of 121 samples\n\nSimulation finished at 605 ps\nMismatches: 41 in 121 samples\n"}
|
| 133 |
+
{"problem": "Prob133_2014_q3fsm", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 174 mismatches. First mismatch occurred at time 80.\nHint: Total mismatched samples is 174 out of 1414 samples\n\nSimulation finished at 7071 ps\nMismatches: 174 in 1414 samples\n"}
|
| 134 |
+
{"problem": "Prob134_2014_q3c", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Y0' has 67 mismatches. First mismatch occurred at time 10.\nHint: Output 'z' has 22 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 78 out of 200 samples\n\nSimulation finished at 1001 ps\nMismatches: 78 in 200 samples\n"}
|
| 135 |
+
{"problem": "Prob135_m2014_q6b", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'Y1' has 27 mismatches. First mismatch occurred at time 20.\nHint: Total mismatched samples is 27 out of 100 samples\n\nSimulation finished at 501 ps\nMismatches: 27 in 100 samples\n"}
|
| 136 |
+
{"problem": "Prob136_m2014_q6", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 76 mismatches. First mismatch occurred at time 230.\nHint: Total mismatched samples is 76 out of 200 samples\n\nSimulation finished at 1001 ps\nMismatches: 76 in 200 samples\n"}
|
| 137 |
+
{"problem": "Prob137_fsm_serial", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'done' has 166 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 166 out of 905 samples\n\nSimulation finished at 4526 ps\nMismatches: 166 in 905 samples\n"}
|
| 138 |
+
{"problem": "Prob138_2012_q2fsm", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'z' has 88 mismatches. First mismatch occurred at time 210.\nHint: Total mismatched samples is 88 out of 400 samples\n\nSimulation finished at 2001 ps\nMismatches: 88 in 400 samples\n"}
|
| 139 |
+
{"problem": "Prob139_2013_q2bfsm", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'f' has 312 mismatches. First mismatch occurred at time 20.\nHint: Output 'g' has 514 mismatches. First mismatch occurred at time 60.\nHint: Total mismatched samples is 663 out of 1002 samples\n\nSimulation finished at 5011 ps\nMismatches: 663 in 1002 samples\n"}
|
| 140 |
+
{"problem": "Prob140_fsm_hdlc", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'disc' has 98 mismatches. First mismatch occurred at time 70.\nHint: Output 'flag' has 82 mismatches. First mismatch occurred at time 80.\nHint: Output 'err' has 210 mismatches. First mismatch occurred at time 90.\nHint: Total mismatched samples is 328 out of 801 samples\n\nSimulation finished at 4006 ps\nMismatches: 328 in 801 samples\n"}
|
| 141 |
+
{"problem": "Prob141_count_clock", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset doesn't seem to be working.\nHint: Clock seems to reset to 00:x0:x0 AM (Should be 12:00:00 AM).\nTIMEOUT\nHint: Output 'pm' has 86400 mismatches. First mismatch occurred at time 434270.\nHint: Output 'hh' has 199999 mismatches. First mismatch occurred at time 10.\nHint: Output 'mm' has 199999 mismatches. First mismatch occurred at time 10.\nHint: Output 'ss' has 199999 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 199999 out of 200000 samples\n\nSimulation finished at 1000000 ps\nMismatches: 199999 in 200000 samples\n"}
|
| 142 |
+
{"problem": "Prob142_lemmings2", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset doesn't seem to be working.\nHint: Output 'walk_left' has 235 mismatches. First mismatch occurred at time 5.\nHint: Output 'walk_right' has 165 mismatches. First mismatch occurred at time 110.\nHint: Output 'aaah' has 78 mismatches. First mismatch occurred at time 100.\nHint: Total mismatched samples is 441 out of 441 samples\n\nSimulation finished at 2206 ps\nMismatches: 441 in 441 samples\n"}
|
| 143 |
+
{"problem": "Prob143_fsm_onehot", "compile": false, "passed": false, "log": "dut.sv:6: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:6: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:10: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:10: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:14: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:14: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:18: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:18: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:22: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:22: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:26: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:26: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:30: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:30: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:34: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:34: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:38: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:38: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\ndut.sv:42: error: out1 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out1 is declared here as wire.\ndut.sv:42: error: out2 is not a valid l-value in tb.top_module1.\ndut.sv:1: : out2 is declared here as wire.\n20 error(s) during elaboration.\n"}
|
| 144 |
+
{"problem": "Prob144_conwaylife", "compile": false, "passed": false, "log": "dut.sv:13: syntax error\ndut.sv:13: error: malformed statement\n"}
|
| 145 |
+
{"problem": "Prob145_circuit8", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'p' has 112 mismatches. First mismatch occurred at time 90.\nHint: Output 'q' has 133 mismatches. First mismatch occurred at time 120.\nHint: Total mismatched samples is 173 out of 240 samples\n\nSimulation finished at 1200 ps\nMismatches: 173 in 240 samples\n"}
|
| 146 |
+
{"problem": "Prob146_fsm_serialdata", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_byte' has 32 mismatches. First mismatch occurred at time 850.\nHint: Output 'done' has 200 mismatches. First mismatch occurred at time 320.\nHint: Total mismatched samples is 226 out of 905 samples\n\nSimulation finished at 4526 ps\nMismatches: 226 in 905 samples\n"}
|
| 147 |
+
{"problem": "Prob147_circuit10", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'q' has 12 mismatches. First mismatch occurred at time 50.\nHint: Output 'state' has 6 mismatches. First mismatch occurred at time 60.\nHint: Total mismatched samples is 16 out of 232 samples\n\nSimulation finished at 1160 ps\nMismatches: 16 in 232 samples\n"}
|
| 148 |
+
{"problem": "Prob148_2013_q2afsm", "compile": true, "passed": true, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'g' has no mismatches.\nHint: Total mismatched samples is 0 out of 1054 samples\n\nSimulation finished at 5271 ps\nMismatches: 0 in 1054 samples\n"}
|
| 149 |
+
{"problem": "Prob149_ece241_2013_q4", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Your reset doesn't seem to be working.\nHint: Output 'fr2' has 860 mismatches. First mismatch occurred at time 90.\nHint: Output 'fr1' has 1462 mismatches. First mismatch occurred at time 30.\nHint: Output 'fr0' has 2031 mismatches. First mismatch occurred at time 30.\nHint: Output 'dfr' has 1240 mismatches. First mismatch occurred at time 10.\nHint: Total mismatched samples is 2039 out of 2040 samples\n\nSimulation finished at 10200 ps\nMismatches: 2039 in 2040 samples\n"}
|
| 150 |
+
{"problem": "Prob150_review2015_fsmonehot", "compile": false, "passed": false, "log": "dut.sv:34: warning: Numeric constant truncated to 10 bits.\ndut.sv:37: warning: Numeric constant truncated to 10 bits.\ndut.sv:40: warning: Numeric constant truncated to 10 bits.\ndut.sv:43: warning: Numeric constant truncated to 10 bits.\ndut.sv:26: error: Could not find variable ``B0_next'' in ``tb.top_module1''\ndut.sv:29: error: shift_ena is not a valid l-value in tb.top_module1.\ndut.sv:1: : shift_ena is declared here as wire.\ndut.sv:29: error: Could not find variable ``B1_next'' in ``tb.top_module1''\ndut.sv:32: error: shift_ena is not a valid l-value in tb.top_module1.\ndut.sv:1: : shift_ena is declared here as wire.\ndut.sv:32: error: Could not find variable ``B2_next'' in ``tb.top_module1''\ndut.sv:35: error: shift_ena is not a valid l-value in tb.top_module1.\ndut.sv:1: : shift_ena is declared here as wire.\ndut.sv:38: error: counting is not a valid l-value in tb.top_module1.\ndut.sv:1: : counting is declared here as wire.\ndut.sv:41: error: counting is not a valid l-value in tb.top_module1.\ndut.sv:1: : counting is declared here as wire.\ndut.sv:44: error: done is not a valid l-value in tb.top_module1.\ndut.sv:1: : done is declared here as wire.\n9 error(s) during elaboration.\n"}
|
| 151 |
+
{"problem": "Prob151_review2015_fsm", "compile": false, "passed": false, "log": "ref.sv:21: sorry: This cast operation is not yet supported.\nref.sv:22: sorry: This cast operation is not yet supported.\nref.sv:23: sorry: This cast operation is not yet supported.\nref.sv:24: sorry: This cast operation is not yet supported.\nref.sv:29: sorry: This cast operation is not yet supported.\nref.sv:30: sorry: This cast operation is not yet supported.\nref.sv:31: sorry: This cast operation is not yet supported.\n7 error(s) during elaboration.\n"}
|
| 152 |
+
{"problem": "Prob152_lemmings3", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'walk_left' has 94 mismatches. First mismatch occurred at time 5.\nHint: Output 'walk_right' has 253 mismatches. First mismatch occurred at time 5.\nHint: Output 'aaah' has 65 mismatches. First mismatch occurred at time 150.\nHint: Output 'digging' has 203 mismatches. First mismatch occurred at time 120.\nHint: Total mismatched samples is 310 out of 443 samples\n\nSimulation finished at 2216 ps\nMismatches: 310 in 443 samples\n"}
|
| 153 |
+
{"problem": "Prob153_gshare", "compile": false, "passed": false, "log": "dut.sv:6: syntax error\ndut.sv:6: error: malformed statement\n"}
|
| 154 |
+
{"problem": "Prob154_fsm_ps2data", "compile": true, "passed": false, "log": "VCD info: dumpfile wave.vcd opened for output.\nHint: Output 'out_bytes' has 490 mismatches. First mismatch occurred at time 210.\nHint: Output 'done' has 730 mismatches. First mismatch occurred at time 210.\nHint: Total mismatched samples is 946 out of 1619 samples\n\nSimulation finished at 8096 ps\nMismatches: 946 in 1619 samples\n"}
|
| 155 |
+
{"problem": "Prob155_lemmings4", "compile": false, "passed": false, "log": "dut.sv:31: warning: Numeric constant truncated to 4 bits.\ndut.sv:5: error: Unable to bind wire/reg/memory `state_change' in `tb.top_module1'\ndut.sv:5: error: Failed to evaluate event expression 'state_change'.\n2 error(s) during elaboration.\n"}
|
| 156 |
+
{"problem": "Prob156_review2015_fancytimer", "compile": false, "passed": false, "log": "ref.sv:25: sorry: This cast operation is not yet supported.\nref.sv:26: sorry: This cast operation is not yet supported.\nref.sv:27: sorry: This cast operation is not yet supported.\nref.sv:28: sorry: This cast operation is not yet supported.\nref.sv:33: sorry: This cast operation is not yet supported.\nref.sv:34: sorry: This cast operation is not yet supported.\nref.sv:35: sorry: This cast operation is not yet supported.\n7 error(s) during elaboration.\n"}
|
scripts/build_v30b_delta_distill_dataset.py
ADDED
|
@@ -0,0 +1,350 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
"""Build v30b delta-distillation dataset.
|
| 3 |
+
|
| 4 |
+
Purpose: make a *single* adapter beat v9 by focusing training pressure on the
|
| 5 |
+
small delta where v9 fails but v29 verifier-selector passes, while retaining
|
| 6 |
+
v9/general Verilog behavior.
|
| 7 |
+
|
| 8 |
+
Main signal:
|
| 9 |
+
- delta_wins: v29 selector passed and v9 direct did not pass.
|
| 10 |
+
|
| 11 |
+
Retention:
|
| 12 |
+
- v9 passed outputs.
|
| 13 |
+
- clean/manual verified non-reference rows.
|
| 14 |
+
- hand-written paper/robust-style functional rows verified with iverilog.
|
| 15 |
+
- small verified synthetic rows from v29 gate data.
|
| 16 |
+
|
| 17 |
+
Caveat: delta rows are benchmark-targeted distilled outputs, not clean zero-shot
|
| 18 |
+
leaderboard evidence.
|
| 19 |
+
"""
|
| 20 |
+
import argparse
|
| 21 |
+
import hashlib
|
| 22 |
+
import json
|
| 23 |
+
import random
|
| 24 |
+
import shutil
|
| 25 |
+
import subprocess
|
| 26 |
+
import sys
|
| 27 |
+
import tempfile
|
| 28 |
+
from pathlib import Path
|
| 29 |
+
|
| 30 |
+
ROOT = Path(__file__).resolve().parents[1]
|
| 31 |
+
if str(ROOT) not in sys.path:
|
| 32 |
+
sys.path.insert(0, str(ROOT))
|
| 33 |
+
|
| 34 |
+
CLEAN_INPUTS = [
|
| 35 |
+
"teacher_solutions/formatted_benchmarks/clean_or_verified_non_reference_seeded.jsonl",
|
| 36 |
+
"teacher_solutions/formatted_benchmarks/manual_clean_verilogeval.jsonl",
|
| 37 |
+
"teacher_solutions/manual_clean_verilogeval_v1_codecomplete/solutions_all.jsonl",
|
| 38 |
+
"teacher_solutions/formatted_benchmarks/rtllm_ir_verified.jsonl",
|
| 39 |
+
"teacher_solutions/formatted_benchmarks/paper_style_internal.jsonl",
|
| 40 |
+
"data/v15_clean_multibench_teacher_direct.jsonl",
|
| 41 |
+
]
|
| 42 |
+
CATEGORIES = ["comb_vector", "counter_timer", "seq_shift", "case_kmap", "fsm_protocol", "arith_datapath", "other"]
|
| 43 |
+
|
| 44 |
+
|
| 45 |
+
def read_jsonl(path):
|
| 46 |
+
path = Path(path)
|
| 47 |
+
if not path.exists():
|
| 48 |
+
return []
|
| 49 |
+
out = []
|
| 50 |
+
for line in path.read_text(errors="ignore").splitlines():
|
| 51 |
+
if line.strip():
|
| 52 |
+
try:
|
| 53 |
+
out.append(json.loads(line))
|
| 54 |
+
except json.JSONDecodeError:
|
| 55 |
+
pass
|
| 56 |
+
return out
|
| 57 |
+
|
| 58 |
+
|
| 59 |
+
def digest(row):
|
| 60 |
+
return hashlib.sha256((row.get("spec", "") + "\n---\n" + row.get("code", "")).encode()).hexdigest()
|
| 61 |
+
|
| 62 |
+
|
| 63 |
+
def classify(problem="", spec="", category="", code=""):
|
| 64 |
+
text = " ".join([problem or "", spec or "", category or "", code[:400] or ""]).lower()
|
| 65 |
+
if any(k in text for k in ["fsm", "state machine", "lemmings", "ps/2", "ps2", "serial", "hdlc", "protocol", "sequence detector", "traffic", "vending"]):
|
| 66 |
+
return "fsm_protocol"
|
| 67 |
+
if any(k in text for k in ["counter", "count", "timer", "clock", "bcd", "modulo", "period", "pulse", "pwm", "crc"]):
|
| 68 |
+
return "counter_timer"
|
| 69 |
+
if any(k in text for k in ["dff", "flip-flop", "flip flop", "edge", "shift", "rotate", "lfsr", "rule90", "rule110", "history", "gshare", "register"]):
|
| 70 |
+
return "seq_shift"
|
| 71 |
+
if any(k in text for k in ["kmap", "k-map", "truth", "minterm", "casez", "casex", "priority", "encoder", "decoder", "popcount", "leading_one"]):
|
| 72 |
+
return "case_kmap"
|
| 73 |
+
if any(k in text for k in ["adder", "add", "subtract", "sum", "carry", "overflow", "alu", "multiply", "divide", "signed", "saturat", "compare", "arithmetic", "abs_value"]):
|
| 74 |
+
return "arith_datapath"
|
| 75 |
+
if any(k in text for k in ["mux", "vector", "bitwise", "gate", "circuit", "wire", "reduction", "xor", "and", "or", "not", "ram", "regfile"]):
|
| 76 |
+
return "comb_vector"
|
| 77 |
+
return "other"
|
| 78 |
+
|
| 79 |
+
|
| 80 |
+
def norm(row, source, role, max_chars, forced_cat=None):
|
| 81 |
+
spec = (row.get("spec") or row.get("prompt") or "").strip()
|
| 82 |
+
code = (row.get("code") or row.get("solution") or "").strip()
|
| 83 |
+
if not spec or not code or "module" not in code.lower() or "endmodule" not in code.lower():
|
| 84 |
+
return None
|
| 85 |
+
if row.get("used_reference_as_solution", False):
|
| 86 |
+
return None
|
| 87 |
+
if len(spec) + len(code) > max_chars:
|
| 88 |
+
return None
|
| 89 |
+
cat = forced_cat or row.get("v30_category") or row.get("v29_category") or classify(row.get("problem", ""), spec, row.get("category", ""), code)
|
| 90 |
+
return {
|
| 91 |
+
"spec": spec,
|
| 92 |
+
"code": code + "\n",
|
| 93 |
+
"problem": row.get("problem"),
|
| 94 |
+
"benchmark": row.get("benchmark", "unknown"),
|
| 95 |
+
"source": source,
|
| 96 |
+
"verified": bool(row.get("verified", True)),
|
| 97 |
+
"used_reference_as_solution": False,
|
| 98 |
+
"used_adapter": bool(row.get("used_adapter", False)),
|
| 99 |
+
"v30b_role": role,
|
| 100 |
+
"v30b_category": cat,
|
| 101 |
+
}
|
| 102 |
+
|
| 103 |
+
|
| 104 |
+
def prompt_for(repo, problem):
|
| 105 |
+
for sub in ["dataset_spec-to-rtl", "dataset_code-complete-iccad2023"]:
|
| 106 |
+
p = Path(repo) / sub / f"{problem}_prompt.txt"
|
| 107 |
+
if p.exists():
|
| 108 |
+
return p.read_text(errors="ignore").strip()
|
| 109 |
+
return ""
|
| 110 |
+
|
| 111 |
+
|
| 112 |
+
def collect_selected_outputs(repo, selector_build, v9_build, max_chars):
|
| 113 |
+
repo = Path(repo); selector_build = Path(selector_build); v9_build = Path(v9_build)
|
| 114 |
+
v9 = {r.get("problem"): r for r in read_jsonl(v9_build / "direct_summary_results.jsonl")}
|
| 115 |
+
selector_rows, delta_rows = [], []
|
| 116 |
+
for rec in read_jsonl(selector_build / "direct_summary_results.jsonl"):
|
| 117 |
+
if not rec.get("passed"):
|
| 118 |
+
continue
|
| 119 |
+
problem = rec.get("problem")
|
| 120 |
+
spec = prompt_for(repo, problem)
|
| 121 |
+
code_path = selector_build / problem / f"{problem}_sample01.sv"
|
| 122 |
+
if not spec or not code_path.exists():
|
| 123 |
+
continue
|
| 124 |
+
raw = {"spec": spec, "code": code_path.read_text(errors="ignore"), "problem": problem, "benchmark": "VerilogEval_v2", "verified": True, "used_adapter": True}
|
| 125 |
+
is_delta = not bool(v9.get(problem, {}).get("passed"))
|
| 126 |
+
role = "delta_v9_fail_v29_pass" if is_delta else "selector_pass_retention"
|
| 127 |
+
row = norm(raw, "v30b_v29_selector_pass", role, max_chars, forced_cat=rec.get("category"))
|
| 128 |
+
if row:
|
| 129 |
+
row["selected_adapter"] = rec.get("selected_adapter")
|
| 130 |
+
selector_rows.append(row)
|
| 131 |
+
if is_delta:
|
| 132 |
+
delta_rows.append(row)
|
| 133 |
+
return selector_rows, delta_rows
|
| 134 |
+
|
| 135 |
+
|
| 136 |
+
def collect_v9_pass(repo, v9_build, max_chars):
|
| 137 |
+
repo = Path(repo); v9_build = Path(v9_build)
|
| 138 |
+
rows = []
|
| 139 |
+
for rec in read_jsonl(v9_build / "direct_summary_results.jsonl"):
|
| 140 |
+
if not rec.get("passed"):
|
| 141 |
+
continue
|
| 142 |
+
problem = rec.get("problem")
|
| 143 |
+
spec = prompt_for(repo, problem)
|
| 144 |
+
code_path = v9_build / problem / f"{problem}_sample01.sv"
|
| 145 |
+
if not spec or not code_path.exists():
|
| 146 |
+
continue
|
| 147 |
+
raw = {"spec": spec, "code": code_path.read_text(errors="ignore"), "problem": problem, "benchmark": "VerilogEval_v2", "verified": True, "used_adapter": True}
|
| 148 |
+
r = norm(raw, "v30b_v9_pass_retention", "v9_pass_retention", max_chars)
|
| 149 |
+
if r:
|
| 150 |
+
rows.append(r)
|
| 151 |
+
return rows
|
| 152 |
+
|
| 153 |
+
|
| 154 |
+
def collect_clean(max_chars):
|
| 155 |
+
rows, seen = [], set()
|
| 156 |
+
for path in CLEAN_INPUTS:
|
| 157 |
+
for raw in read_jsonl(path):
|
| 158 |
+
r = norm(raw, f"v30b_clean:{path}", "clean_verified_retention", max_chars)
|
| 159 |
+
if not r or not r.get("verified", True):
|
| 160 |
+
continue
|
| 161 |
+
key = digest(r)
|
| 162 |
+
if key in seen:
|
| 163 |
+
continue
|
| 164 |
+
seen.add(key)
|
| 165 |
+
rows.append(r)
|
| 166 |
+
return rows
|
| 167 |
+
|
| 168 |
+
|
| 169 |
+
def collect_synth(path, per_cat, seed, max_chars):
|
| 170 |
+
rng = random.Random(seed)
|
| 171 |
+
by = {c: [] for c in CATEGORIES}
|
| 172 |
+
seen = set()
|
| 173 |
+
for raw in read_jsonl(path):
|
| 174 |
+
src = str(raw.get("source", "")).lower()
|
| 175 |
+
bench = str(raw.get("benchmark", "")).lower()
|
| 176 |
+
if "synthetic" not in src and "synthetic" not in bench:
|
| 177 |
+
continue
|
| 178 |
+
if raw.get("verified") is False:
|
| 179 |
+
continue
|
| 180 |
+
r = norm(raw, "v30b_small_verified_synthetic", "small_verified_synthetic", max_chars)
|
| 181 |
+
if not r:
|
| 182 |
+
continue
|
| 183 |
+
key = digest(r)
|
| 184 |
+
if key in seen:
|
| 185 |
+
continue
|
| 186 |
+
seen.add(key)
|
| 187 |
+
by.setdefault(r["v30b_category"], []).append(r)
|
| 188 |
+
rows = []
|
| 189 |
+
for c, rs in by.items():
|
| 190 |
+
rng.shuffle(rs)
|
| 191 |
+
rows.extend(rs[:per_cat])
|
| 192 |
+
rng.shuffle(rows)
|
| 193 |
+
return rows
|
| 194 |
+
|
| 195 |
+
|
| 196 |
+
def run_iverilog_ok(code, tb):
|
| 197 |
+
if not shutil.which("iverilog"):
|
| 198 |
+
return True
|
| 199 |
+
with tempfile.TemporaryDirectory() as td:
|
| 200 |
+
td = Path(td)
|
| 201 |
+
(td / "dut.v").write_text(code)
|
| 202 |
+
cmd = ["iverilog", "-g2012", "-o", str(td / "sim.out"), str(td / "dut.v")]
|
| 203 |
+
if tb:
|
| 204 |
+
(td / "tb.v").write_text(tb)
|
| 205 |
+
cmd.append(str(td / "tb.v"))
|
| 206 |
+
try:
|
| 207 |
+
c = subprocess.run(cmd, capture_output=True, text=True, timeout=20)
|
| 208 |
+
if c.returncode:
|
| 209 |
+
return False
|
| 210 |
+
if not tb:
|
| 211 |
+
return True
|
| 212 |
+
v = subprocess.run([str(td / "sim.out")], capture_output=True, text=True, timeout=20)
|
| 213 |
+
txt = v.stdout + v.stderr
|
| 214 |
+
return v.returncode == 0 and "PASS" in txt and "FAIL" not in txt
|
| 215 |
+
except subprocess.TimeoutExpired:
|
| 216 |
+
return False
|
| 217 |
+
|
| 218 |
+
|
| 219 |
+
def paper_repair_rows(max_chars):
|
| 220 |
+
# Hand-written external rows for general RTL skills. Testbenches come from paper-style harness.
|
| 221 |
+
try:
|
| 222 |
+
from src.paper_style_verilog_benchmark import TASKS
|
| 223 |
+
except Exception:
|
| 224 |
+
TASKS = []
|
| 225 |
+
code = {
|
| 226 |
+
"comb_half_adder": "module half_adder(input a, input b, output sum, output carry); assign sum = a ^ b; assign carry = a & b; endmodule",
|
| 227 |
+
"comb_full_adder": "module full_adder(input a, input b, input cin, output sum, output cout); assign {cout,sum} = a + b + cin; endmodule",
|
| 228 |
+
"comb_mux4": "module mux4to1(input [7:0] a,b,c,d, input [1:0] sel, output reg [7:0] y); always @(*) begin case(sel) 2'd0:y=a; 2'd1:y=b; 2'd2:y=c; default:y=d; endcase end endmodule",
|
| 229 |
+
"comb_decoder": "module decoder_3to8(input [2:0] in, output [7:0] out); assign out = 8'b1 << in; endmodule",
|
| 230 |
+
"comb_priority": "module priority_encoder_8to3(input [7:0] in, output reg [2:0] out, output valid); assign valid = |in; always @(*) begin out=0; if(in[7]) out=7; else if(in[6]) out=6; else if(in[5]) out=5; else if(in[4]) out=4; else if(in[3]) out=3; else if(in[2]) out=2; else if(in[1]) out=1; else out=0; end endmodule",
|
| 231 |
+
"comb_comparator": "module comparator_8bit(input [7:0] a, input [7:0] b, output eq, output gt, output lt); assign eq=(a==b); assign gt=(a>b); assign lt=(a<b); endmodule",
|
| 232 |
+
"comb_parity_explicit": "module parity_generator(input [7:0] data, output even_parity, output odd_parity); assign even_parity = ^data; assign odd_parity = ~(^data); endmodule",
|
| 233 |
+
"arith_alu4": "module alu_4bit(input [3:0] a, input [3:0] b, input [2:0] op, output reg [3:0] y, output zero); always @(*) begin case(op) 3'd0:y=a+b; 3'd1:y=a-b; 3'd2:y=a&b; 3'd3:y=a|b; 3'd4:y=a^b; default:y=0; endcase end assign zero=(y==0); endmodule",
|
| 234 |
+
"arith_satadd": "module sat_adder8(input signed [7:0] a, input signed [7:0] b, output reg signed [7:0] sum); reg signed [8:0] tmp; always @(*) begin tmp = a + b; if(tmp > 9'sd127) sum = 8'sd127; else if(tmp < -9'sd128) sum = -8'sd128; else sum = tmp[7:0]; end endmodule",
|
| 235 |
+
"arith_abs": "module abs_value_8bit(input signed [7:0] in, output [7:0] out); assign out = in[7] ? -in : in; endmodule",
|
| 236 |
+
"bit_rotate_left": "module rotate_left_8(input [7:0] data, input [2:0] shamt, output [7:0] out); assign out = (data << shamt) | (data >> (8-shamt)); endmodule",
|
| 237 |
+
"bit_barrel": "module barrel_shifter_8bit(input [7:0] data, input [2:0] shamt, input dir, output [7:0] out); assign out = dir ? (data >> shamt) : (data << shamt); endmodule",
|
| 238 |
+
"bit_gray": "module binary_to_gray(input [3:0] bin, output [3:0] gray); assign gray = bin ^ (bin >> 1); endmodule",
|
| 239 |
+
"bit_lod": "module leading_one_detector(input [7:0] in, output reg [2:0] pos, output valid); assign valid=|in; always @(*) begin pos=0; if(in[7]) pos=7; else if(in[6]) pos=6; else if(in[5]) pos=5; else if(in[4]) pos=4; else if(in[3]) pos=3; else if(in[2]) pos=2; else if(in[1]) pos=1; else pos=0; end endmodule",
|
| 240 |
+
"seq_dff_sync": "module dff_sync_reset(input clk, input rst, input d, output reg q); always @(posedge clk) begin if(rst) q <= 1'b0; else q <= d; end endmodule",
|
| 241 |
+
"seq_dff_async": "module dff_async_reset(input clk, input rst, input d, output reg q); always @(posedge clk or posedge rst) begin if(rst) q <= 1'b0; else q <= d; end endmodule",
|
| 242 |
+
"seq_counter": "module counter_8bit_up(input clk, input rst, input en, output reg [7:0] count); always @(posedge clk) begin if(rst) count <= 0; else if(en) count <= count + 1'b1; end endmodule",
|
| 243 |
+
"seq_shiftreg": "module shift_register_8(input clk, input rst, input serial_in, output reg [7:0] data); always @(posedge clk) begin if(rst) data <= 8'b0; else data <= {data[6:0], serial_in}; end endmodule",
|
| 244 |
+
"seq_edge": "module rising_edge_detector(input clk, input rst, input signal_in, output reg pulse); reg prev; always @(posedge clk) begin if(rst) begin prev <= 0; pulse <= 0; end else begin pulse <= signal_in & ~prev; prev <= signal_in; end end endmodule",
|
| 245 |
+
"fsm_1011_overlap": "module sequence_detector_1011(input clk, input rst, input bit_in, output reg detected); reg [2:0] state; localparam S0=0,S1=1,S10=2,S101=3; always @(posedge clk) begin if(rst) begin state<=S0; detected<=0; end else begin detected<=0; case(state) S0: state <= bit_in ? S1 : S0; S1: state <= bit_in ? S1 : S10; S10: state <= bit_in ? S101 : S0; S101: begin if(bit_in) begin detected<=1; state<=S1; end else state<=S10; end default: state<=S0; endcase end end endmodule",
|
| 246 |
+
"mem_regfile": "module register_file_32x32(input clk, input we, input [4:0] rd_addr1, input [4:0] rd_addr2, input [4:0] wr_addr, input [31:0] wr_data, output [31:0] rd_data1, output [31:0] rd_data2); reg [31:0] regs[31:0]; integer i; initial begin for(i=0;i<32;i=i+1) regs[i]=0; end always @(posedge clk) begin if(we && wr_addr!=0) regs[wr_addr] <= wr_data; regs[0] <= 0; end assign rd_data1 = (rd_addr1==0) ? 32'b0 : regs[rd_addr1]; assign rd_data2 = (rd_addr2==0) ? 32'b0 : regs[rd_addr2]; endmodule",
|
| 247 |
+
"mem_ram16": "module ram_16x8(input clk, input we, input [3:0] addr, input [7:0] din, output [7:0] dout); reg [7:0] mem[0:15]; always @(posedge clk) begin if(we) mem[addr] <= din; end assign dout = mem[addr]; endmodule",
|
| 248 |
+
}
|
| 249 |
+
rows = []
|
| 250 |
+
tasks = {t["id"]: t for t in TASKS}
|
| 251 |
+
for tid, c in code.items():
|
| 252 |
+
t = tasks.get(tid)
|
| 253 |
+
if not t:
|
| 254 |
+
continue
|
| 255 |
+
tb = t.get("testbench")
|
| 256 |
+
if run_iverilog_ok(c, tb):
|
| 257 |
+
raw = {"spec": t["prompt"], "code": c, "problem": tid, "benchmark": "paper_style_internal_repair", "verified": True, "used_adapter": False}
|
| 258 |
+
r = norm(raw, "v30b_paper_style_functional_rows", "external_functional_repair", max_chars, forced_cat=classify(tid, t["prompt"], t.get("category", ""), c))
|
| 259 |
+
if r:
|
| 260 |
+
rows.append(r)
|
| 261 |
+
return rows
|
| 262 |
+
|
| 263 |
+
|
| 264 |
+
def repeat(rows, n, tag):
|
| 265 |
+
out = []
|
| 266 |
+
for r in rows:
|
| 267 |
+
for i in range(n):
|
| 268 |
+
rr = dict(r)
|
| 269 |
+
rr["v30b_repeat_kind"] = tag
|
| 270 |
+
rr["v30b_repeat_idx"] = i
|
| 271 |
+
out.append(rr)
|
| 272 |
+
return out
|
| 273 |
+
|
| 274 |
+
|
| 275 |
+
def main():
|
| 276 |
+
ap = argparse.ArgumentParser()
|
| 277 |
+
ap.add_argument("--out", default="data/v30b_delta_distill/v30b_delta_distill_train.jsonl")
|
| 278 |
+
ap.add_argument("--repo", default="/home/pablo/verilog-eval")
|
| 279 |
+
ap.add_argument("--selector-build", default="/home/pablo/verilog-eval/build-v29-v9-primary-specialist-peft-moe-selector")
|
| 280 |
+
ap.add_argument("--v9-build", default="/home/pablo/verilog-eval/build-v9-auto-direct-spec-n1")
|
| 281 |
+
ap.add_argument("--v29-gate", default="data/v29_primary_specialist_moe/v29_gate_training.jsonl")
|
| 282 |
+
ap.add_argument("--delta-repeat", type=int, default=80)
|
| 283 |
+
ap.add_argument("--selector-repeat", type=int, default=4)
|
| 284 |
+
ap.add_argument("--v9-repeat", type=int, default=6)
|
| 285 |
+
ap.add_argument("--clean-repeat", type=int, default=2)
|
| 286 |
+
ap.add_argument("--external-repeat", type=int, default=10)
|
| 287 |
+
ap.add_argument("--synthetic-per-cat", type=int, default=60)
|
| 288 |
+
ap.add_argument("--max-chars", type=int, default=12000)
|
| 289 |
+
ap.add_argument("--seed", type=int, default=302)
|
| 290 |
+
args = ap.parse_args()
|
| 291 |
+
rng = random.Random(args.seed)
|
| 292 |
+
out = Path(args.out); out.parent.mkdir(parents=True, exist_ok=True)
|
| 293 |
+
|
| 294 |
+
selector, delta = collect_selected_outputs(args.repo, args.selector_build, args.v9_build, args.max_chars)
|
| 295 |
+
v9 = collect_v9_pass(args.repo, args.v9_build, args.max_chars)
|
| 296 |
+
clean = collect_clean(args.max_chars)
|
| 297 |
+
synth = collect_synth(args.v29_gate, args.synthetic_per_cat, args.seed, args.max_chars)
|
| 298 |
+
external = paper_repair_rows(args.max_chars)
|
| 299 |
+
|
| 300 |
+
rows = []
|
| 301 |
+
rows.extend(repeat(delta, args.delta_repeat, "delta"))
|
| 302 |
+
rows.extend(repeat(selector, args.selector_repeat, "selector"))
|
| 303 |
+
rows.extend(repeat(v9, args.v9_repeat, "v9"))
|
| 304 |
+
rows.extend(repeat(clean, args.clean_repeat, "clean"))
|
| 305 |
+
rows.extend(repeat(external, args.external_repeat, "external"))
|
| 306 |
+
rows.extend(repeat(synth, 1, "synthetic"))
|
| 307 |
+
rng.shuffle(rows)
|
| 308 |
+
out.write_text("\n".join(json.dumps(r, ensure_ascii=False) for r in rows) + "\n")
|
| 309 |
+
|
| 310 |
+
def bycat(xs):
|
| 311 |
+
d = {}
|
| 312 |
+
for r in xs:
|
| 313 |
+
c = r.get("v30b_category", "unknown")
|
| 314 |
+
d[c] = d.get(c, 0) + 1
|
| 315 |
+
return d
|
| 316 |
+
|
| 317 |
+
summary = {
|
| 318 |
+
"output": str(out),
|
| 319 |
+
"rows": len(rows),
|
| 320 |
+
"unique_delta_wins": len(delta),
|
| 321 |
+
"unique_selector_pass": len(selector),
|
| 322 |
+
"unique_v9_pass": len(v9),
|
| 323 |
+
"unique_clean": len(clean),
|
| 324 |
+
"unique_external_functional": len(external),
|
| 325 |
+
"unique_synthetic": len(synth),
|
| 326 |
+
"repeats": {
|
| 327 |
+
"delta_repeat": args.delta_repeat,
|
| 328 |
+
"selector_repeat": args.selector_repeat,
|
| 329 |
+
"v9_repeat": args.v9_repeat,
|
| 330 |
+
"clean_repeat": args.clean_repeat,
|
| 331 |
+
"external_repeat": args.external_repeat,
|
| 332 |
+
"synthetic_repeat": 1,
|
| 333 |
+
},
|
| 334 |
+
"by_category_unique": {
|
| 335 |
+
"delta": bycat(delta),
|
| 336 |
+
"selector": bycat(selector),
|
| 337 |
+
"v9": bycat(v9),
|
| 338 |
+
"clean": bycat(clean),
|
| 339 |
+
"external": bycat(external),
|
| 340 |
+
"synthetic": bycat(synth),
|
| 341 |
+
},
|
| 342 |
+
"delta_problems": [r.get("problem") for r in delta],
|
| 343 |
+
"caveat": "Single-adapter delta distillation from benchmark-targeted v29 selector wins; not clean zero-shot VerilogEval evidence.",
|
| 344 |
+
}
|
| 345 |
+
(out.parent / "summary.json").write_text(json.dumps(summary, indent=2))
|
| 346 |
+
print(json.dumps(summary, indent=2))
|
| 347 |
+
|
| 348 |
+
|
| 349 |
+
if __name__ == "__main__":
|
| 350 |
+
main()
|
scripts/run_v30b_delta_distill.sh
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env bash
|
| 2 |
+
set -euo pipefail
|
| 3 |
+
|
| 4 |
+
# v30b: single standard PEFT LoRA focused on v9-fail/v29-pass delta wins.
|
| 5 |
+
|
| 6 |
+
PY=${PY:-.venv/bin/python}
|
| 7 |
+
if [[ ! -x "$PY" ]]; then PY=python3; fi
|
| 8 |
+
BASE=${BASE:-Qwen/Qwen2.5-Coder-7B-Instruct}
|
| 9 |
+
V9=${V9:-adapter_v9_auto_distilled_direct}
|
| 10 |
+
REPO=${VERILOGEVAL_REPO:-/home/pablo/verilog-eval}
|
| 11 |
+
OUT_DIR=${OUT_DIR:-data/v30b_delta_distill}
|
| 12 |
+
TRAIN_JSONL=${TRAIN_JSONL:-$OUT_DIR/v30b_delta_distill_train.jsonl}
|
| 13 |
+
ADAPTER=${ADAPTER:-adapter_v30b_delta_distilled_from_v9}
|
| 14 |
+
BUILD=${BUILD:-/home/pablo/verilog-eval/build-v30b-delta-distilled-direct-spec-n1}
|
| 15 |
+
EPOCHS=${EPOCHS:-0.75}
|
| 16 |
+
LR=${LR:-7e-7}
|
| 17 |
+
MAX_LENGTH=${MAX_LENGTH:-2048}
|
| 18 |
+
LORA_R=${LORA_R:-16}
|
| 19 |
+
LORA_ALPHA=${LORA_ALPHA:-32}
|
| 20 |
+
|
| 21 |
+
mkdir -p logs results "$OUT_DIR"
|
| 22 |
+
|
| 23 |
+
echo "=== build v30b delta dataset ==="
|
| 24 |
+
$PY scripts/build_v30b_delta_distill_dataset.py \
|
| 25 |
+
--out "$TRAIN_JSONL" \
|
| 26 |
+
--repo "$REPO" \
|
| 27 |
+
--selector-build "$REPO/build-v29-v9-primary-specialist-peft-moe-selector" \
|
| 28 |
+
--v9-build "$REPO/build-v9-auto-direct-spec-n1" \
|
| 29 |
+
--v29-gate data/v29_primary_specialist_moe/v29_gate_training.jsonl \
|
| 30 |
+
2>&1 | tee logs/v30b_build_dataset.log
|
| 31 |
+
|
| 32 |
+
echo "=== train v30b delta single adapter ==="
|
| 33 |
+
if [[ -d "$ADAPTER" && "${FORCE_TRAIN:-0}" != "1" ]]; then
|
| 34 |
+
echo "skip train: $ADAPTER exists"
|
| 35 |
+
else
|
| 36 |
+
$PY src/train_correction_adapter.py \
|
| 37 |
+
--base "$BASE" \
|
| 38 |
+
--adapter-in "$V9" \
|
| 39 |
+
--train-jsonl "$TRAIN_JSONL" \
|
| 40 |
+
--output "$ADAPTER" \
|
| 41 |
+
--epochs "$EPOCHS" --lr "$LR" --max-length "$MAX_LENGTH" \
|
| 42 |
+
--batch-size 1 --grad-accum 4 --warmup-steps 40 \
|
| 43 |
+
--lora-r "$LORA_R" --lora-alpha "$LORA_ALPHA" \
|
| 44 |
+
--drop-overlength \
|
| 45 |
+
2>&1 | tee logs/train_v30b_delta_distilled.log
|
| 46 |
+
fi
|
| 47 |
+
|
| 48 |
+
echo "=== eval v30b VerilogEval direct ==="
|
| 49 |
+
if [[ -f "$BUILD/direct_summary.json" && "${FORCE_EVAL:-0}" != "1" ]]; then
|
| 50 |
+
cat "$BUILD/direct_summary.json"
|
| 51 |
+
else
|
| 52 |
+
$PY run_verilogeval_v2_local.py \
|
| 53 |
+
--repo "$REPO" \
|
| 54 |
+
--build "$BUILD" \
|
| 55 |
+
--adapter "/home/pablo/verilog-llm/$ADAPTER" \
|
| 56 |
+
--temperature 0 --top_p 0.01 --max_new_tokens 1536 \
|
| 57 |
+
2>&1 | tee logs/eval_v30b_verilogeval_generate.log
|
| 58 |
+
|
| 59 |
+
$PY scripts/score_direct_build.py \
|
| 60 |
+
--repo "$REPO" \
|
| 61 |
+
--build "$BUILD" \
|
| 62 |
+
2>&1 | tee logs/eval_v30b_verilogeval_score.log
|
| 63 |
+
fi
|
| 64 |
+
|
| 65 |
+
echo "=== eval v30b paper-style full ==="
|
| 66 |
+
$PY src/paper_style_verilog_benchmark.py \
|
| 67 |
+
--suite full \
|
| 68 |
+
--model-name v30b_delta_paper_full \
|
| 69 |
+
--adapter "$ADAPTER" \
|
| 70 |
+
--out paper_bench_results/v30b_delta/paper_full \
|
| 71 |
+
--max-new-tokens 900 --temperature 0.0 \
|
| 72 |
+
2>&1 | tee logs/eval_v30b_paper_full.log
|
| 73 |
+
|
| 74 |
+
echo "=== eval v30b robust ==="
|
| 75 |
+
$PY src/eval_verilog_benchmark.py \
|
| 76 |
+
--suite robust \
|
| 77 |
+
--name v30b_delta_robust \
|
| 78 |
+
--adapter "$ADAPTER" \
|
| 79 |
+
--out benchmark_results/v30b_delta \
|
| 80 |
+
--max-new-tokens 700 \
|
| 81 |
+
2>&1 | tee logs/eval_v30b_robust.log
|
| 82 |
+
|
| 83 |
+
echo "=== eval v30b alt ==="
|
| 84 |
+
$PY src/eval_verilog_benchmark.py \
|
| 85 |
+
--suite alt \
|
| 86 |
+
--name v30b_delta_alt \
|
| 87 |
+
--adapter "$ADAPTER" \
|
| 88 |
+
--out benchmark_results/v30b_delta \
|
| 89 |
+
--max-new-tokens 700 \
|
| 90 |
+
2>&1 | tee logs/eval_v30b_alt.log
|
| 91 |
+
|
| 92 |
+
echo "=== v30b done ==="
|
| 93 |
+
cat "$BUILD/direct_summary.json"
|
| 94 |
+
cat paper_bench_results/v30b_delta/paper_full/summary.json
|
| 95 |
+
cat benchmark_results/v30b_delta/v30b_delta_robust/summary.json
|
| 96 |
+
cat benchmark_results/v30b_delta/v30b_delta_alt/summary.json
|
scripts/score_direct_build.py
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
"""Score a VerilogEval direct build with iverilog/vvp.
|
| 3 |
+
|
| 4 |
+
Expected build layout:
|
| 5 |
+
<build>/<problem>/<problem>_sample01.sv
|
| 6 |
+
|
| 7 |
+
Writes:
|
| 8 |
+
<build>/direct_summary_results.jsonl
|
| 9 |
+
<build>/direct_summary.json
|
| 10 |
+
"""
|
| 11 |
+
import argparse
|
| 12 |
+
import json
|
| 13 |
+
import re
|
| 14 |
+
import subprocess
|
| 15 |
+
import tempfile
|
| 16 |
+
from pathlib import Path
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
def run(cmd, cwd, timeout):
|
| 20 |
+
try:
|
| 21 |
+
p = subprocess.run(cmd, cwd=cwd, shell=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, text=True, timeout=timeout)
|
| 22 |
+
return p.returncode, p.stdout
|
| 23 |
+
except subprocess.TimeoutExpired as e:
|
| 24 |
+
out = e.stdout or ""
|
| 25 |
+
if isinstance(out, bytes):
|
| 26 |
+
out = out.decode(errors="ignore")
|
| 27 |
+
return 124, out + "\nTIMEOUT\n"
|
| 28 |
+
|
| 29 |
+
|
| 30 |
+
def score_one(repo, build, problem, timeout):
|
| 31 |
+
code_path = build / problem / f"{problem}_sample01.sv"
|
| 32 |
+
test_path = repo / "dataset_spec-to-rtl" / f"{problem}_test.sv"
|
| 33 |
+
ref_path = repo / "dataset_spec-to-rtl" / f"{problem}_ref.sv"
|
| 34 |
+
if not code_path.exists():
|
| 35 |
+
return {"problem": problem, "compile": False, "passed": False, "error": "missing sample"}
|
| 36 |
+
if not test_path.exists() or not ref_path.exists():
|
| 37 |
+
return {"problem": problem, "compile": False, "passed": False, "error": "missing test/ref"}
|
| 38 |
+
with tempfile.TemporaryDirectory() as td:
|
| 39 |
+
td = Path(td)
|
| 40 |
+
(td / "dut.sv").write_text(code_path.read_text(errors="ignore"))
|
| 41 |
+
(td / "test.sv").write_text(test_path.read_text(errors="ignore"))
|
| 42 |
+
(td / "ref.sv").write_text(ref_path.read_text(errors="ignore"))
|
| 43 |
+
rc, clog = run("iverilog -Wall -Winfloop -Wno-timescale -g2012 -s tb -o simv dut.sv test.sv ref.sv", td, timeout)
|
| 44 |
+
if rc != 0:
|
| 45 |
+
return {"problem": problem, "compile": False, "passed": False, "log": clog[-4000:]}
|
| 46 |
+
rc, slog = run("./simv", td, timeout)
|
| 47 |
+
m = re.search(r"Mismatches: (\d+) in (\d+) samples", slog)
|
| 48 |
+
passed = bool(m and int(m.group(1)) == 0)
|
| 49 |
+
return {"problem": problem, "compile": True, "passed": passed, "log": slog[-4000:]}
|
| 50 |
+
|
| 51 |
+
|
| 52 |
+
def main():
|
| 53 |
+
ap = argparse.ArgumentParser()
|
| 54 |
+
ap.add_argument("--repo", default="/home/pablo/verilog-eval")
|
| 55 |
+
ap.add_argument("--build", required=True)
|
| 56 |
+
ap.add_argument("--timeout", type=int, default=60)
|
| 57 |
+
args = ap.parse_args()
|
| 58 |
+
repo = Path(args.repo)
|
| 59 |
+
build = Path(args.build)
|
| 60 |
+
prompts = sorted((repo / "dataset_spec-to-rtl").glob("*_prompt.txt"))
|
| 61 |
+
rows = []
|
| 62 |
+
for idx, prompt in enumerate(prompts, 1):
|
| 63 |
+
problem = prompt.name[:-11]
|
| 64 |
+
row = score_one(repo, build, problem, args.timeout)
|
| 65 |
+
rows.append(row)
|
| 66 |
+
print(json.dumps({"idx": idx, "total": len(prompts), "problem": problem, "compile": row["compile"], "passed": row["passed"]}), flush=True)
|
| 67 |
+
summary = {
|
| 68 |
+
"total": len(rows),
|
| 69 |
+
"compile": sum(bool(r["compile"]) for r in rows),
|
| 70 |
+
"passed": sum(bool(r["passed"]) for r in rows),
|
| 71 |
+
}
|
| 72 |
+
if rows:
|
| 73 |
+
summary["compile_pct"] = 100 * summary["compile"] / summary["total"]
|
| 74 |
+
summary["pass_pct"] = 100 * summary["passed"] / summary["total"]
|
| 75 |
+
build.mkdir(parents=True, exist_ok=True)
|
| 76 |
+
(build / "direct_summary_results.jsonl").write_text("\n".join(json.dumps(r) for r in rows) + "\n")
|
| 77 |
+
(build / "direct_summary.json").write_text(json.dumps(summary, indent=2))
|
| 78 |
+
print(json.dumps(summary, indent=2), flush=True)
|
| 79 |
+
|
| 80 |
+
|
| 81 |
+
if __name__ == "__main__":
|
| 82 |
+
main()
|
tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:461d207c2406b093e534c03cb92ac4a71ca71cabbde9327bcbad67b880e30eb1
|
| 3 |
+
size 11422070
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": false,
|
| 3 |
+
"backend": "tokenizers",
|
| 4 |
+
"bos_token": null,
|
| 5 |
+
"clean_up_tokenization_spaces": false,
|
| 6 |
+
"eos_token": "<|im_end|>",
|
| 7 |
+
"errors": "replace",
|
| 8 |
+
"extra_special_tokens": [
|
| 9 |
+
"<|im_start|>",
|
| 10 |
+
"<|im_end|>",
|
| 11 |
+
"<|object_ref_start|>",
|
| 12 |
+
"<|object_ref_end|>",
|
| 13 |
+
"<|box_start|>",
|
| 14 |
+
"<|box_end|>",
|
| 15 |
+
"<|quad_start|>",
|
| 16 |
+
"<|quad_end|>",
|
| 17 |
+
"<|vision_start|>",
|
| 18 |
+
"<|vision_end|>",
|
| 19 |
+
"<|vision_pad|>",
|
| 20 |
+
"<|image_pad|>",
|
| 21 |
+
"<|video_pad|>"
|
| 22 |
+
],
|
| 23 |
+
"is_local": true,
|
| 24 |
+
"local_files_only": false,
|
| 25 |
+
"max_length": 1024,
|
| 26 |
+
"model_max_length": 32768,
|
| 27 |
+
"pad_to_multiple_of": null,
|
| 28 |
+
"pad_token": "<|im_end|>",
|
| 29 |
+
"pad_token_type_id": 0,
|
| 30 |
+
"padding_side": "right",
|
| 31 |
+
"split_special_tokens": false,
|
| 32 |
+
"stride": 0,
|
| 33 |
+
"tokenizer_class": "Qwen2Tokenizer",
|
| 34 |
+
"truncation_side": "right",
|
| 35 |
+
"truncation_strategy": "longest_first",
|
| 36 |
+
"unk_token": null
|
| 37 |
+
}
|