{"id":304,"date":"2013-04-26T08:55:00","date_gmt":"2013-04-26T08:55:00","guid":{"rendered":"http:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/?page_id=304"},"modified":"2018-11-20T12:31:23","modified_gmt":"2018-11-20T12:31:23","slug":"cll6i23dcl","status":"publish","type":"page","link":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/software\/applications\/naglibraries\/cll6i23dcl\/","title":{"rendered":"Mark 23 C using Intel Compiler (CLL6I23DCL)"},"content":{"rendered":"<h2>Overview<\/h2>\n<p>This is the C version of the NAG library. Run the following module commands to load the environment for the Intel Compiler and the relevant NAG library<\/p>\n<pre>\r\nmodule load compilers\/intel\/c\/12.0.5\r\nmodule load libs\/intel\/nag\/c_mark23_intel\r\n<\/pre>\n<p>This will set the following environment variable for easy access to the libraries, header files and example scripts:<\/p>\n<pre>\r\nNAG_HOME_CLL6I23DCL=\/opt\/gridware\/libs\/intel\/nag\/cll6i23dcl\r\n<\/pre>\n<h2>Compiling the example programs<\/h2>\n<p>The NAG library ships with example programs for every routine available.  The directory <\/p>\n<pre>\r\n$NAG_HOME_CLL6I23DCL\/scripts\r\n<\/pre>\n<p>contains four scripts:<\/p>\n<pre>\r\nnag_example_mkl\r\nnag_example_shar_mkl\r\nnag_example\r\nnag_example_shar\r\n<\/pre>\n<p>which provide easy to use interfaces to compile, link and run each of these examples. This <em>scripts<\/em> directory is added to your PATH environment variable for convenience. The differences between these scripts are shown below:<\/p>\n<ul>\n<li><strong>nagc_example_mkl<\/strong>, to link with the NAG static library libnagc_mkl.a and the supplied MKL libraries<\/li>\n<li><strong>nagc_example_shar_mkl<\/strong>, to link with the NAG shareable library libnagc_mkl.so and the supplied MKL libraries<\/li>\n<li><strong>nagc_example<\/strong>, to link with the NAG self-contained static library libnagc_nag.a<\/li>\n<li><strong>nagc_example_shar<\/strong>, to link with the NAG self-contained shareable library libnagc_nag.so<\/li>\n<\/ul>\n<p>These can be used to inform you how to compile the NAG library according to your needs. For example, to compile,link and run the example for the routine <strong>a00aac<\/strong> using the NAG static library libnagc_mkl.a and the NAG-supplied MKL libraries you would run<\/p>\n<pre>\r\nnagc_example_mkl a00aac\r\n<\/pre>\n<p>The output from this script is<\/p>\n<pre>\r\nCopying a00aace.c to current directory\r\ncp \/software\/libs\/intel\/nag\/cll6i23dcl\/examples\/source\/a00aace.c .\r\n\r\nCompiling and linking a00aace.c to produce executable a00aace.exe\r\nicc a00aace.c -I\/software\/libs\/intel\/nag\/cll6i23dcl\/include -m64 \\\r\n      \/software\/libs\/intel\/nag\/cll6i23dcl\/lib\/libnagc_mkl.a -Wl,--start-group \\\r\n      \/software\/libs\/intel\/nag\/cll6i23dcl\/mkl_intel64\/libmkl_intel_ilp64.a \\\r\n      \/software\/libs\/intel\/nag\/cll6i23dcl\/mkl_intel64\/libmkl_intel_thread.a \\\r\n      \/software\/libs\/intel\/nag\/cll6i23dcl\/mkl_intel64\/libmkl_core.a \\\r\n      -Wl,--end-group -openmp -lpthread -lm -o  a00aace.exe\r\n\r\nRunning a00aace.exe\r\n.\/a00aace.exe > a00aace.r\r\n<\/pre>\n<p>Among other things, the above shows you the form of the icc command that NAG recommend for this usage case. The output from running the example will be contained in the file 00aace.r<br \/>\nTo submit and run the above job on CSF you might use the following submission script<\/p>\n<pre>\r\n#!\/bin\/bash\r\n#$ -S \/bin\/bash\r\n#$ -N NAGExample\r\n#$ -cwd\r\n#$ -o outputfile.log\r\n#$ -j y\r\n#$ -V\r\n\r\n.\/a00aace.exe > a00aace.r\r\n<\/pre>\n<p><a href=\"http:\/\/www.nag.co.uk\/doc\/inun\/cl23\/l6idcl\/un.html\">CLL6I23DCL User&#8217;s note<\/a> &#8211; detailed library usage notes from NAG<br \/>\n<a href=\"http:\/\/www.nag.co.uk\/numeric\/CL\/nagdoc_cl23\/html\/FRONTMATTER\/manconts.html\">Mark 23 C Library Manual<\/a> &#8211; Includes details of all routines<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview This is the C version of the NAG library. Run the following module commands to load the environment for the Intel Compiler and the relevant NAG library module load compilers\/intel\/c\/12.0.5 module load libs\/intel\/nag\/c_mark23_intel This will set the following environment variable for easy access to the libraries, header files and example scripts: NAG_HOME_CLL6I23DCL=\/opt\/gridware\/libs\/intel\/nag\/cll6i23dcl Compiling the example programs The NAG library ships with example programs for every routine available. The directory $NAG_HOME_CLL6I23DCL\/scripts contains four scripts: nag_example_mkl.. <a href=\"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/software\/applications\/naglibraries\/cll6i23dcl\/\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":293,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-304","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/304","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/comments?post=304"}],"version-history":[{"count":6,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/304\/revisions"}],"predecessor-version":[{"id":4313,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/304\/revisions\/4313"}],"up":[{"embeddable":true,"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/pages\/293"}],"wp:attachment":[{"href":"https:\/\/ri.itservices.manchester.ac.uk\/csf-apps\/wp-json\/wp\/v2\/media?parent=304"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}