Fast, Scalable Phrase-Based SMT Decoding

Hieu Hoang, Nikolay Bogoychev, Lane Schwartz, Marcin Junczys-Dowmunt

Abstract: Hieu Hoang, Nikolay Bogoychev, Lane Schwartz, Marcin Junczys-Dowmunt. Conferences of the Association for Machine Translation in the Americas: MT Researchers' Track.

2016.

Introduction

Statistical Machine Translation (SMT) has long been the backbone of commercial translation services, with the open-source Moses decoder serving as the industry standard. However, Moses was designed before the era of ubiquitous many-core processors. In modern server environments, Moses faces a significant scalability bottleneck: adding more CPU cores does not necessarily improve performance. This research introduces a high-performance, drop-in replacement for Moses that achieves up to 15x speedup through architectural re-engineering and "monotonic scaling."

The Scalability Problem

The primary bottleneck in Moses is its inability to scale efficiently on modern hardware. Performance often decreases after 15 or 16 threads because CPU cores spend more time on locking contention—fighting over shared resources—than on translation. This paper aims to fix these architectural inefficiencies by optimizing memory management and internal data lookups.

Methods

The authors optimized four specific areas of the decoding process to eliminate internal bottlenecks:

1. Custom Memory Management

Instead of relying on the operating system's general-purpose memory allocation, which requires slow synchronization between threads, the researchers implemented thread-specific memory pools. Each thread manages its own memory independently, eliminating locking contention. Additionally, using Last-In-First-Out (LIFO) queues for high-churn objects increased CPU cache hits.

2. Optimized Stack Configuration

The researchers moved away from simple "coverage cardinality" stacks to a configuration that tracks both coverage and the end position of the last translated word. This reduces the number of expensive checks required to enforce distortion limits.

Model score vs. decode time for different stack configurations, showing the efficiency of the 'coverage + end pos' approach.

3. Phrase-Table Refinement

  • Static Caching: A static cache of common translation rules provided a 10% speed boost.
  • Disabling Compression: By disabling target-side compression, the authors traded disk space for speed, eliminating the CPU overhead of decompressing data on the fly.

4. Model Integration

The "lexicalized re-ordering model" was integrated directly into the phrase table, eliminating redundant search operations and separate random-access lookups.

Datasets and Evaluation

The decoder was evaluated on two distinct tasks to ensure generalizability:

  • Arabic-English (ar-en): A large model with short sentences (Opus corpus).
  • French-English (fr-en): A smaller model with long sentences (Europarl corpus).

Evaluation sets included OpenSubtitles for ar-en and newstest2011 for fr-en to measure both translation quality and speed.

Key Results

The optimized decoder demonstrates significant performance gains and, crucially, monotonic scaling—performance continues to improve or stay stable as more cores are added.

Throughput comparison showing that the new decoder achieves monotonic scaling while Moses performance degrades at high thread counts.
  • Raw Speedup: The new decoder is 4.4x faster than Moses on a single thread.
  • Multicore Dominance: On a 32-thread server, the decoder is 14.5x faster than Moses for French-English translation.
  • Efficiency: Memory management overhead was slashed from nearly 40% in Moses to just 13%.

Limitations and Future Work

While the phrase table and memory management are now highly optimized, the Language Model (LM) component remains a significant bottleneck, accounting for up to 38% of execution time. Future work will focus on optimizing LM querying and extending these optimizations to other search algorithms beyond Cube Pruning.

Summary updated

BibTeX
@inproceedings{hoang2016fast,
  author = {Hieu Hoang and Nikolay Bogoychev and Lane Schwartz and Marcin Junczys-Dowmunt},
  title = {{Fast, Scalable Phrase-Based SMT Decoding}},
  booktitle = {AMTA},
  year = {2016},
  url = {https://openreview.net/forum?id=6LHLs0N4KC},
}
Figure