Skip to content

Commit b0b18ec

Browse files
sameeran joshizmodem
sameeran joshi
authored andcommitted
[Flang] Fix release blocker issue llvm#46931 related to documentation.
Summary: Fixes bug : https://bugs.llvm.org/show_bug.cgi?id=46931 This commit add a new flag -DLLVM_ENABLE_SPHINX=ON to cmake command to generate sphinx documentation, along with new cmake targets `docs-flang-html`. `ninja docs-flang-html` - generates sphinx documentation. Generated release notes are present in <builddir>/tools/flang/docs/html/ folder. Reviewers: richard.barton.arm, DavidTruby Tags: #flang Differential Revision: https://reviews.llvm.org/D85470 (cherry picked from commit 2fc86cc)
1 parent 7bcb12a commit b0b18ec

File tree

9 files changed

+858
-0
lines changed

9 files changed

+858
-0
lines changed

flang/docs/ReleaseNotes.rst

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
========================================
2+
Flang 11.0.0 (In-Progress) Release Notes
3+
========================================
4+
5+
.. contents::
6+
:local:
7+
:depth: 2
8+
9+
.. warning::
10+
11+
These are in-progress notes for the upcoming LLVM 11.0.0 release.
12+
Release notes for previous releases can be found on
13+
`the Download Page <https://releases.llvm.org/download.html>`_.
14+
15+
Introduction
16+
============
17+
18+
This document contains the release notes for the Flang Fortran
19+
frontend, part of the LLVM Compiler Infrastructure, release 11.0.0. Here we
20+
describe the status of Flang in some detail, including major
21+
improvements from the previous release and new feature work. For the
22+
general LLVM release notes, see `the LLVM
23+
documentation <https://llvm.org/docs/ReleaseNotes.html>`_. All LLVM
24+
releases may be downloaded from the `LLVM releases web
25+
site <https://llvm.org/releases/>`_.
26+
27+
Note that if you are reading this file from a Git checkout, this document
28+
applies to the *next* release, not
29+
the current one. To see the release notes for a specific release, please
30+
see the `releases page <https://llvm.org/releases/>`_.
31+
32+
Known Issues
33+
============
34+
35+
These are issues that couldn't be fixed before the release. See the bug reports for the latest status.
36+
37+
- ...
38+
39+
Introducing Flang
40+
=================
41+
42+
Flang is LLVM's Fortran front end and is new for the LLVM 11 release.
43+
44+
Flang is still a work in progress for this release and is included for
45+
experimentation and feedback.
46+
47+
Flang status
48+
------------
49+
50+
Flang is able to parse a comprehensive subset of the Fortran language
51+
and check it for correctness. Flang is not yet able to generate LLVM IR for
52+
the source code and thus is unable to compile a running binary.
53+
54+
Flang is able to unparse the input source code into a canonical form and emit
55+
it to allow testing. Flang can also invoke an external Fortran compiler on this
56+
canonical input.
57+
58+
Flang's parser has comprehensive support for:
59+
- Fortran 2018
60+
- OpenMP 4.5
61+
- OpenACC 3.0
62+
63+
Major missing features
64+
----------------------
65+
66+
- Flang is not supported on Windows platforms.
67+
68+
Using Flang
69+
===========
70+
71+
Usage: ``flang hello.f90 -o hello.bin``
72+
73+
Flang will parse the Fortran file ``hello.f90`` then unparse it to a canonical
74+
Fortran source file. Flang will then invoke an external Fortran compiler to
75+
compile this source file and link it, placing the resulting executable
76+
in ``hello.bin``.
77+
78+
To specify the external Fortran compiler, set the ``F18_FC`` environment
79+
variable to the name of the compiler binary and ensure it is on your ``PATH``.
80+
The default value for ``F18_FC`` is ``gfortran``.
81+
82+
When invoked with no source input, Flang will wait for input on standard in.
83+
When invoked in this way, Flang performs the same actions as if called with
84+
``-fdebug-measure-parse-tree -funparse`` and does not invoke ``F18_FC``.
85+
86+
For a full list of options that Flang supports, run ``flang --help``.
87+
88+
Additional Information
89+
======================
90+
91+
Flang's documentation is located in the ``flang/docs/`` directory in
92+
the LLVM monorepo.
93+
94+
If you have any questions or comments about Flang, please feel free to
95+
contact us via the `mailing
96+
list <https://lists.llvm.org/mailman/listinfo/flang-dev>`_.

flang/docs/_static/llvm.css

Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
/*
2+
* LLVM documentation style sheet
3+
*/
4+
5+
/* Common styles */
6+
.body { color: black; background: white; margin: 0 0 0 0 }
7+
8+
/* No borders on image links */
9+
a:link img, a:visited img { border-style: none }
10+
11+
address img { float: right; width: 88px; height: 31px; }
12+
address { clear: right; }
13+
14+
table { text-align: center; border: 2px solid black;
15+
border-collapse: collapse; margin-top: 1em; margin-left: 1em;
16+
margin-right: 1em; margin-bottom: 1em; }
17+
tr, td { border: 2px solid gray; padding: 4pt 4pt 2pt 2pt; }
18+
th { border: 2px solid gray; font-weight: bold; font-size: 105%;
19+
background: url("lines.gif");
20+
font-family: "Georgia,Palatino,Times,Roman,SanSerif";
21+
text-align: center; vertical-align: middle; }
22+
/*
23+
* Documentation
24+
*/
25+
/* Common for title and header */
26+
.doc_title, .doc_section, .doc_subsection, h1, h2, h3 {
27+
color: black; background: url("lines.gif");
28+
font-family: "Georgia,Palatino,Times,Roman,SanSerif"; font-weight: bold;
29+
border-width: 1px;
30+
border-style: solid none solid none;
31+
text-align: center;
32+
vertical-align: middle;
33+
padding-left: 8pt;
34+
padding-top: 1px;
35+
padding-bottom: 2px
36+
}
37+
38+
h1, .doc_title, .title { text-align: left; font-size: 25pt }
39+
40+
h2, .doc_section { text-align: center; font-size: 22pt;
41+
margin: 20pt 0pt 5pt 0pt; }
42+
43+
h3, .doc_subsection { width: 75%;
44+
text-align: left; font-size: 12pt;
45+
padding: 4pt 4pt 4pt 4pt;
46+
margin: 1.5em 0.5em 0.5em 0.5em }
47+
48+
h4, .doc_subsubsection { margin: 2.0em 0.5em 0.5em 0.5em;
49+
font-weight: bold; font-style: oblique;
50+
border-bottom: 1px solid #999999; font-size: 12pt;
51+
width: 75%; }
52+
53+
.doc_author { text-align: left; font-weight: bold; padding-left: 20pt }
54+
.doc_text { text-align: left; padding-left: 20pt; padding-right: 10pt }
55+
56+
.doc_footer { text-align: left; padding: 0 0 0 0 }
57+
58+
.doc_hilite { color: blue; font-weight: bold; }
59+
60+
.doc_table { text-align: center; width: 90%;
61+
padding: 1px 1px 1px 1px; border: 1px; }
62+
63+
.doc_warning { color: red; font-weight: bold }
64+
65+
/* <div class="doc_code"> would use this class, and <div> adds more padding */
66+
.doc_code, .literal-block
67+
{ border: solid 1px gray; background: #eeeeee;
68+
margin: 0 1em 0 1em;
69+
padding: 0 1em 0 1em;
70+
display: table;
71+
}
72+
73+
blockquote pre {
74+
padding: 1em 2em 1em 1em;
75+
border: solid 1px gray;
76+
background: #eeeeee;
77+
margin: 0 1em 0 1em;
78+
display: table;
79+
}
80+
81+
h2+div, h2+p {text-align: left; padding-left: 20pt; padding-right: 10pt;}
82+
h3+div, h3+p {text-align: left; padding-left: 20pt; padding-right: 10pt;}
83+
h4+div, h4+p {text-align: left; padding-left: 20pt; padding-right: 10pt;}
84+
85+
/* It is preferable to use <pre class="doc_code"> everywhere instead of the
86+
* <div class="doc_code"><pre>...</ptr></div> construct.
87+
*
88+
* Once all docs use <pre> for code regions, this style can be merged with the
89+
* one above, and we can drop the [pre] qualifier.
90+
*/
91+
pre.doc_code, .literal-block { padding: 1em 2em 1em 1em }
92+
93+
.doc_notes { background: #fafafa; border: 1px solid #cecece;
94+
display: table; padding: 0 1em 0 .1em }
95+
96+
table.layout { text-align: left; border: none; border-collapse: collapse;
97+
padding: 4px 4px 4px 4px; }
98+
tr.layout, td.layout, td.left, td.right
99+
{ border: none; padding: 4pt 4pt 2pt 2pt; vertical-align: top; }
100+
td.left { text-align: left }
101+
td.right { text-align: right }
102+
th.layout { border: none; font-weight: bold; font-size: 105%;
103+
text-align: center; vertical-align: middle; }
104+
105+
/* Left align table cell */
106+
.td_left { border: 2px solid gray; text-align: left; }
107+
108+
/* ReST-specific */
109+
.title { margin-top: 0 }
110+
.topic-title{ display: none }
111+
div.contents ul { list-style-type: decimal }
112+
.toc-backref { color: black; text-decoration: none; }
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{#
2+
sphinxdoc/layout.html
3+
~~~~~~~~~~~~~~~~~~~~~
4+
5+
Sphinx layout template for the sphinxdoc theme.
6+
7+
:copyright: Copyright 2007-2010 by the Sphinx team, see AUTHORS.
8+
:license: BSD, see LICENSE for details.
9+
#}
10+
{% extends "basic/layout.html" %}
11+
12+
{% block relbar1 %}
13+
<div class="logo">
14+
<a href="{{ pathto('index') }}">
15+
<img src="{{pathto("_static/logo.png", 1) }}"
16+
alt="LLVM Logo" width="250" height="88"/></a>
17+
</div>
18+
{{ super() }}
19+
{% endblock %}
20+
21+
{# put the sidebar before the body #}
22+
{% block sidebar1 %}{{ sidebar() }}{% endblock %}
23+
{% block sidebar2 %}{% endblock %}
202 Bytes
Loading

0 commit comments

Comments
 (0)