7 research outputs found

    The complexity of two finite-state models, optimizing transducers and counting automata

    Get PDF
    An optimizing finite-state transducer is a nondeterministic finite-state transducer in which states are either maximizing or minimizing. In a given state, the optimal output is the maximum or minimum--over all possible transitions--of the transition output concatenated with the optimal output of the resulting state. The ranges of optimizing finite-state transducers form a class in NL which includes a hierarchy based on the number of alternations of maximizing and minimizing states in a computation. The inequivalence problem--whether or not two transducers compute different functions, and the range inequivalence problem are shown to be undecidable. Some other problems associated with this model are shown to be complete for NL and NP;A counting finite-state automaton is a nondeterministic finite-state automaton which, on an input over its input alphabet, (magically) writes in binary the number of accepting computations on the input. We examine the complexity of computing the counting function of an NFA, and the complexity of recognizing its range as a set of binary strings. We also consider the pumping behavior of counting finite-state automata. The class of functions computed by counting NFAs (1) includes a class of functions computed by deterministic finite-state transducers; (2) is contained in the class of functions computed by polynomially time- and linearly space-bounded Turing transducers; (3) includes a function whose range is the composite numbers

    On the equivalence, containment, and covering problems for the regular and context-free languages

    Get PDF
    We consider the complexity of the equivalence and containment problems for regular expressions and context-free grammars, concentrating on the relationship between complexity and various language properties. Finiteness and boundedness of languages are shown to play important roles in the complexity of these problems. An encoding into grammars of Turing machine computations exponential in the size of the grammar is used to prove several exponential lower bounds. These lower bounds include exponential time for testing equivalence of grammars generating finite sets, and exponential space for testing equivalence of non-self-embedding grammars. Several problems which might be complex because of this encoding are shown to simplify for linear grammars. Other problems considered include grammatical covering and structural equivalence for right-linear, linear, and arbitrary grammars

    Parallel parsing made practical

    Get PDF
    The property of local parsability allows to parse inputs through inspecting only a bounded-length string around the current token. This in turn enables the construction of a scalable, data-parallel parsing algorithm, which is presented in this work. Such an algorithm is easily amenable to be automatically generated via a parser generator tool, which was realized, and is also presented in the following. Furthermore, to complete the framework of a parallel input analysis, a parallel scanner can also combined with the parser. To prove the practicality of a parallel lexing and parsing approach, we report the results of the adaptation of JSON and Lua to a form fit for parallel parsing (i.e. an operator-precedence grammar) through simple grammar changes and scanning transformations. The approach is validated with performance figures from both high performance and embedded multicore platforms, obtained analyzing real-world inputs as a test-bench. The results show that our approach matches or dominates the performances of production-grade LR parsers in sequential execution, and achieves significant speedups and good scaling on multi-core machines. The work is concluded by a broad and critical survey of the past work on parallel parsing and future directions on the integration with semantic analysis and incremental parsing
    corecore