Nothing Special   »   [go: up one dir, main page]

skip to main content
10.1145/2502488.2502492acmconferencesArticle/Chapter ViewAbstractPublication PagesicfpConference Proceedingsconference-collections
research-article

N queens problem: a metaprogramming stress test for the compiler

Published: 28 September 2013 Publication History

Abstract

A metaprogram solving N queens problem is written using Boost MPL library. The solution is tested using different compilers to examine the level of their practical use for complex metaprogramming tasks. The corresponding benchmark results were obtained.

Supplementary Material

ZIP File (wgp05.zip)
The supplied material includes a full source code for the meta-queens program described in the paper. Along with a ReadMe file with all the information on Used software, tested compilers, Archive contents and Build options

References

[1]
D. Abrahams, and A. Gurtovoy. C++ Template Metaprogramming: Concepts, Tools, and Techniques from Boost and Beyond. Addison-Wesley Professional, 2004. 400 pp. ISBN-10: 0-321-22725-5.
[2]
A gentle introduction to Template Metaprogramming with C++. URL: http://www.codeproject.com/Articles/3743/A-gentle-introduction-to-Template-Metaprogramming
[3]
A. Alexandrescu. Modern C++ Design: Generic Programming and Design Patterns Applied. Addison-Wesley Professional, 2001. 352 pp. ISBN-10: 0-201-70431-5.
[4]
But. . . but. . . It's still compiling! URL: http://debugfailure.wordpress.com/2009/12/16/but-but-its-still-compiling/
[5]
Compute nth prime at compile time. URL: http://stackoverflow.com/questions/15289678/compute-nth-prime-at-compile-time
[6]
Enumerate all the 8 queens placements on a chessboard such that they cannot attach each other (in Russian). URL: http://algolist.manual.ru/maths/combinat/queens.php
[7]
Metaprogramming in C++ (in Russian). URL: http://habrahabr.ru/post/38622/
[8]
Solve the eight queens problem at compile-time. URL: http://codegolf.stackexchange.com/questions/3184/solve-the-eight-queens-problem-at-compile-time
[9]
S. Tambe. Faster meta-programs using gcc 4.5 and C++0x. 2010. URL: http://cpptruths.blogspot.ru/2010/03/faster-meta-programs-using-gcc-45-and.html
[10]
The Boost MPL Library. URL: http://www.boost.org/doc/libs/1_53_0/libs/mpl/doc/index.html
[11]
E. Unruh. Prime number computation. ANSI X3J16-94-0075/ISOWG21-462. 1994.
[12]
J. Walker. Template Metaprogramming. Overload Journal, 46, 2001. URL: http://accu.org/index.php/journals/424

Cited By

View all
  • (2014)Moving computations from run-time to compile-timeProceedings of the 11th ACM Conference on Computing Frontiers10.1145/2597917.2597933(1-10)Online publication date: 20-May-2014

Recommendations

Comments

Please enable JavaScript to view thecomments powered by Disqus.

Information & Contributors

Information

Published In

cover image ACM Conferences
WGP '13: Proceedings of the 9th ACM SIGPLAN workshop on Generic programming
September 2013
92 pages
ISBN:9781450323895
DOI:10.1145/2502488
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 28 September 2013

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. boost
  2. clang
  3. constexpr
  4. gcc
  5. mpl
  6. queens puzzle

Qualifiers

  • Research-article

Conference

ICFP'13
Sponsor:

Acceptance Rates

WGP '13 Paper Acceptance Rate 8 of 14 submissions, 57%;
Overall Acceptance Rate 30 of 43 submissions, 70%

Upcoming Conference

ICFP '25
ACM SIGPLAN International Conference on Functional Programming
October 12 - 18, 2025
Singapore , Singapore

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)2
  • Downloads (Last 6 weeks)1
Reflects downloads up to 21 Nov 2024

Other Metrics

Citations

Cited By

View all
  • (2014)Moving computations from run-time to compile-timeProceedings of the 11th ACM Conference on Computing Frontiers10.1145/2597917.2597933(1-10)Online publication date: 20-May-2014

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media