Search arXiv⌕ Search

arXiv subjects

Nicolai Fiege

Publications and source records attributed to Nicolai Fiege.

2 recordsLinked to original sources

Reopening Pandora's Box: Complexity Results of Shift-Addition/Subtraction Sequences

Multiplication by constants is a fundamental operation in digital hardware design, with applications in many different areas. Costly generic multipliers are commonly replaced by tailored sequences of shift and add/subtract operations, giving rise to the Single Constant, Multiple Constant and Constant Matrix Multiplication (SCM, MCM, CMM) problems, and their pipelined variants (PSCM, PMCM, PCMM) in which operation outputs are registered and leave the same pipeline stage. Exact synthesis approaches based on SAT, ILP or CP are routinely observed to scale exponentially, and the problems have long been treated as intractable. The exact complexity classification of the shift-add straight-line program formulation has remained open, though, and the results usually cited as evidence of NP-hardness concern different computational models or do not transfer by polynomial-time reduction. Here we close this gap for five problems: we show that CMM, MCM, PMCM, PCMM, and MCM with fixed topology are all NP-complete. NP-hardness of CMM and PCMM hold for targets over binary vectors with only three non-zero entries already, the remaining three hold for targets with three non-zero digits in Canonical Signed Digit representation. We also show that these restrictions are tight, because the fragment over two non-zeros is decidable in polynomial time. Hardness therefore does not stem from complexity of the individual targets but rather from the combinatorial structure of the target set and the interaction between the targets.

cs.CC↗

Decompose, Optimize, and Reconstruct: Very Large Constant Multiplication at Scale

Efficient arithmetic circuit design for resourceconstrained hardware involves challenging combinatorial optimization problems, among which Multiple Constant Multiplication (MCM) is a prominent example. MCM aims at implementing multiplications by fixed integer constants using bit-shifts and additions/subtractions but optimal methods are typically limited to moderately-sized constants, e.g. 12 bits. For practical applications targeting larger precision, Very large Constant Multiplication (VLCM) is solved instead. Existing approaches typically address VLCM through a heuristic flow that decomposes large constants into patterns, applies MCM optimization techniques on moderately-sized targets, and reconstructs the final result. This paper proposes multiple improvements to this flow: new declarative optimization models for the pattern selection and for the reconstruction, as well as applying recent optimal MCM models. The cornerstones of the obtained improvements are (i) allowing the patterns to overlap, minimising the number of unique target constants for the MCM step and (ii) performing the reconstruction step optimally, instead of heuristically. In addition, we propose a globally-optimal VLCM approach and characterize its limits. We employ a mix of constraint programming and SAT to solve each step. Experimental results on synthetic and real-life signal processing and cryptographic benchmarks, with coefficient word lengths ranging from tens to thousands of bits, demonstrate that the proposed approach scales to very large precisions and consistently outperforms existing baselines.

cs.AR↗