polyphony-dev / polyphony Goto Github PK
View Code? Open in Web Editor NEWPolyphony is Python based High-Level Synthesis compiler.
License: MIT License
Polyphony is Python based High-Level Synthesis compiler.
License: MIT License
hello.
The details.
polyphony xor5.py
Traceback (most recent call last):
File "c:\users\ore\anaconda3\lib\runpy.py", line 193, in _run_module_as_main "__main__", mod_spec)
File "c:\users\ore\anaconda3\lib\runpy.py", line 85, in _run_code exec(code, run_globals)
File "C:\Users\ore\Anaconda3\Scripts\polyphony.exe\__main__.py", line 9, in <module>
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\__main__.py", line 858, in main compile_main(options.source, options)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\__main__.py", line 787, in compile_main compile_results = compile(compile_plan(), main_source, src_file)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\__main__.py", line 780, in compile driver.run()
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\driver.py",line 76, in run proc(self, s)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\__main__.py", line 380, in constopt_pre_detectrom ConstantOptPreDetectROM().process(scope)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\constopt.py", line 264, in process self.visit(stm)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\irvisitor.py", line 31, in visit return visitor(ir)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\constopt.py", line 176, in visit_CJUMP self._process_unconditional_cjump(ir, [])
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\constopt.py", line 239, in _process_unconditional_cjump remove_dominated_branch(false_blk)
File "c:\users\ore\anaconda3\lib\site-packages\polyphony\compiler\constopt.py", line 214, in remove_dominated_branch phi.args.pop(idx)
IndexError: pop index out of range
(base)
polyphony 0.3.6
Python 3.6.0
The source is this.
https://qiita.com/ohisama@github/items/5b010d66b97f1cf770a6
nice to meet you.
Traceback (most recent call last):
File "/Users/<user>/.virtualenvs/polyphony/bin/polyphony", line 4, in <module>
main()
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/__main__.py", line 395, in main
compile_main(src_file, options.output_name, options.output_dir, options.debug_mode)
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/__main__.py", line 309, in compile_main
IRTranslator().translate(read_source(src_file))
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/irtranslator.py", line 811, in translate
visitor.visit(tree)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ast.py", line 253, in visit
return visitor(node)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ast.py", line 261, in generic_visit
self.visit(item)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ast.py", line 253, in visit
return visitor(node)
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/irtranslator.py", line 196, in visit_FunctionDef
self.visit(stm)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ast.py", line 253, in visit
return visitor(node)
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/irtranslator.py", line 241, in visit_Return
self.emit(MOVE(ret, self.visit(node.value)), node)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/ast.py", line 253, in visit
return visitor(node)
File "/Users/<user>/.virtualenvs/polyphony/lib/python3.6/site-packages/polyphony/compiler/irtranslator.py", line 642, in visit_Call
if node.starargs:
AttributeError: 'Call' object has no attribute 'starargs'
It does not have the problem on version 0.2.0.
I have a custom array interface implementation that takes 4 steps to complete a write (rather than the default of 2), I'm having issues where if I use it in a loop the the last 2 steps get truncated. I've changed the n_step being used to 4 and the increased the latency of MSTORE and I've traced it back to an issue in the scheduler. It appears that the jump in the forbody back to the fortest does not depend on mstores in the loop body:
Here's the schedule for the block:
Node 6046 0 0:0 @cond565:bool = (i#2:int[32] < @t560:int[32]) @top.const_multiply_fortest2
Node 608c 1 0:1 cjump @cond565:bool ? @top.const_multiply_forbody3, @top.const_multiply_forelse5 @top.const_multiply_fortest2
Node ba6a 0 0:3 @t566:int[32] = ys:list[int[32]][i#2:int[32]] @top.const_multiply_forbody3
Node 459a 0 0:0 i#3:int[32] = (i#2:int[32] + 0x1) @top.const_multiply_forbody3
Node ba5c 1 3:3 t:int[32] = (@t566:int[32] * x:int[32]) @top.const_multiply_forbody3
Node ba4e 2 3:6 mstore(ys:list[int[32]][i#2:int[32]], t:int[32]) @top.const_multiply_forbody3
Node bacc 3 3:4 i#2:int[32] = i#3:int[32] @top.const_multiply_forbody3
Node 45af 4 4:5 jump @top.const_multiply_fortest2 'L' @top.const_multiply_forbody3
You can see that the mstore ends on state 6 but the jump back begins on state 4. The state reducer then removes states 5, 6 because they can't be reached.
Traceback (most recent call last):
File "/polyphony/tests/apps/ad7091r.py", line 91, in /polyphony/polyphony/init.py", line 57, in _testbench_decorator
test(spic)
File "
func(module_instance)
File "/polyphony/polyphony/init.py", line 297, in wrapper/polyphony/tests/apps/ad7091r.py", line 86, in test
return func(*args, **kwargs)
File "
assert spic.dout() == data & 0x0fff
AssertionError
dout value is 3419
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.