Skip to content
This repository was archived by the owner on Jan 12, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
6792992
Update runtime capability names in SDK and command-line parser (#826)
bamarsha Jan 26, 2021
d9179f6
Continue with CI even if style check has errors (#838)
bamarsha Jan 26, 2021
da03122
[Docgen] Hide internal, ```Q# → ```qsharp, and fix ms.topic. (#839)
Jan 27, 2021
e8b14eb
Adding project templates for targeted executables (#840)
bettinaheim Jan 28, 2021
1d373d4
Updated sourceName fields of new templates. (#842)
ScottCarda-MS Jan 28, 2021
3dd0d10
Allow .NET 5 in global.json and build with .NET 5 in CI (#841)
bamarsha Jan 29, 2021
d6d298c
Added Template ReadMe File (#843)
ScottCarda-MS Jan 29, 2021
71c8e26
minor progress
Feb 4, 2021
6e7c99c
properly filtering monomorphized versions of built-in callables
Feb 4, 2021
0fd70bd
this should be ok I think and avoid mem copy
Feb 4, 2021
ccdfc4f
fixing an issue with discarded loop variables
Feb 4, 2021
000d027
support for DoubleAsInt
Feb 5, 2021
eb3b82b
fixing truncate
Feb 9, 2021
9920f2e
Update pinned version for yeoman-environment (#858)
ricardo-espinoza Feb 9, 2021
77a9600
hacky setup to handle integer powers; looses precision and needs revi…
Feb 9, 2021
472ef63
using 128bit floating point for integer exponentiation
Feb 9, 2021
32925a0
Interpolated String Delimiters (#735)
ScottCarda-MS Feb 11, 2021
89fda48
fixing reference counts (tests are not yet updated)
Feb 11, 2021
5db3703
pointer comparison to determine if copy was executed
Feb 11, 2021
a658c1b
removing unnecessary usings
Feb 11, 2021
925bec5
adapting tests
Feb 12, 2021
f0e48df
getelementptr -> getelementptr inbounds
Feb 12, 2021
964477f
don't bother building trivial partial applications
Feb 12, 2021
0ddea54
adding all changes together
Feb 12, 2021
cc6147a
removing warnings
Feb 12, 2021
2494e87
fixing warnings
Feb 12, 2021
806eb5d
Add Q# source code formatter (#845)
bamarsha Feb 12, 2021
1fd018a
Resolve the default access modifier to Public or Internal in the synt…
bamarsha Feb 13, 2021
7c2649f
First attempt at standalone LLVM wrapper
swernli Jan 27, 2021
7b439f4
More fixes, unit tests running but failing
swernli Jan 29, 2021
4eee0d0
Remove Resources usage
swernli Jan 29, 2021
d18f1cc
Use default instead of null
swernli Jan 29, 2021
bcb0f3c
Fix null dereference
swernli Feb 4, 2021
1fce989
Add readme
swernli Feb 4, 2021
bad4dc5
Rearrange files into single project
swernli Feb 4, 2021
af0ecd4
Clean up warnings
swernli Feb 4, 2021
e30dcb8
Fix incorrect instruction generation (tests pass!)
swernli Feb 4, 2021
d6ecb48
Remove cached Llvm.NET dlls
swernli Feb 8, 2021
fe7197e
Fix sln
swernli Feb 8, 2021
191b085
Add singing for Llvm.NET project
swernli Feb 8, 2021
4d45ad7
Try suppressing strong name requirement
swernli Feb 8, 2021
118d9f8
Update to LLVMSharp 11.0.0-beta
swernli Feb 11, 2021
9d59e67
Adding alignment to unit tests
swernli Feb 12, 2021
a85f6ff
Fix unit tests
swernli Feb 14, 2021
f3bc0ba
Merge remote-tracking branch 'origin/main' into swernli/standalone-ll…
swernli Feb 15, 2021
2386adb
Fix QsNullable
swernli Feb 15, 2021
e70f7d4
use 64-bit fp precision for integer exponentiation
Feb 15, 2021
5a87594
Merge remote-tracking branch 'origin/beheim/vqeRun' into swernli/stan…
swernli Feb 16, 2021
f9255ff
committing the minimal example that captures the problem
Feb 16, 2021
6c57e77
quick and dirty fixes
Feb 16, 2021
9655709
Temporarily remove Example.csproj
swernli Feb 16, 2021
8f8d4c4
Merge remote-tracking branch 'origin/beheim/vqeRun' into swernli/stan…
swernli Feb 16, 2021
6758d78
Temporarily skip execution tests
swernli Feb 16, 2021
efc60e5
full VQE
Feb 16, 2021
c86c96c
Revert "Temporarily remove Example.csproj"
swernli Feb 16, 2021
a85ffe0
Revert "Temporarily skip execution tests"
swernli Feb 16, 2021
aab1ac8
Switch to updated Runtime package
swernli Feb 16, 2021
9c12a46
Update legal nices and copyrights
swernli Feb 16, 2021
56d9f76
Add pointer to NOTICE in Llvm.NET readme
swernli Feb 17, 2021
ddc64c4
Explicitly support ubuntu 18.04
swernli Feb 17, 2021
235fa49
some progress with the entry point arg handling
Feb 18, 2021
7aeb66d
removing the generate interop wrapper function
Feb 18, 2021
788aaaa
Simplify resolution of file edit to avoid unnecessary execute command…
ricardo-espinoza Feb 20, 2021
f3c27b2
fixing an issue with nested conditionals
Feb 22, 2021
5616742
adding a test to the conditionals
Feb 22, 2021
68dd11e
Merge remote-tracking branch 'origin/beheim/vqeRun' into swernli/stan…
swernli Feb 22, 2021
f173c67
Fix new conditional unit test for LLVM 11
swernli Feb 22, 2021
3d3a445
Fixing "ret void" QIR bug
swernli Feb 22, 2021
45a1bc3
update lodash to 4.17.21 for security fix (#878)
anjbur Feb 23, 2021
99ee952
Revert "Fixing "ret void" QIR bug"
swernli Feb 23, 2021
365b26b
Update scope of quantumDevKit.languageServerPath config variable. (#872)
ricardo-espinoza Feb 23, 2021
49a273c
Fix generation of continue blocks from conditionals.
swernli Feb 23, 2021
d2f3de6
Fixing duplicate intrinsics (#880)
swernli Feb 25, 2021
722ec70
Produce bitcode file when generating QIR
swernli Feb 25, 2021
92446bd
Merge remote-tracking branch 'origin/main' into swernli/standalone-ll…
swernli Feb 26, 2021
431a552
first draft also for return type mapping
Mar 5, 2021
0cd2781
arg mapping class is no longer needed
Mar 5, 2021
468d755
NuGet compliance changes (#887)
anjbur Mar 5, 2021
d6ee334
Merge remote-tracking branch 'origin/main' into swernli/standalone-ll…
swernli Mar 5, 2021
817cb04
splitting out functions
Mar 6, 2021
3d44bca
undo changes to NuGet.config from PR#887 (#888)
anjbur Mar 6, 2021
70c1663
basic pauli, bool, and range mapping
Mar 7, 2021
c8e8503
GenerateEntryPoint should be ok
Mar 8, 2021
b4dee93
removing all dependencies on runtime types and instead rely on a mall…
Mar 8, 2021
5b3ac5e
getting updates from feature branch
Mar 8, 2021
05adb8e
Merge remote-tracking branch 'origin/main' into swernli/standalone-ll…
swernli Mar 8, 2021
ab52c50
doc comments
Mar 9, 2021
8d0090c
properly splitting out the interop tools into their own class
Mar 9, 2021
c4b2407
Merge remote-tracking branch 'origin/feature/qir' into swernli/standa…
swernli Mar 10, 2021
0edd4ed
Fix file formatting
swernli Mar 10, 2021
e1c9a7e
Update src/QsCompiler/QirGeneration/QirGeneration.csproj
swernli Mar 10, 2021
cf74bd8
Update src/QsCompiler/QirGeneration/Subtransformations/ExpressionKind…
swernli Mar 10, 2021
9f58175
Update src/QsCompiler/QirGeneration/Subtransformations/ExpressionKind…
swernli Mar 10, 2021
0d10b35
Update and renames for CR feedback
swernli Mar 10, 2021
320711f
Put back missing examples
swernli Mar 11, 2021
3f612e7
getting updates from llvm sharp merge
Mar 11, 2021
4c5b42b
Merge branch 'swernli/standalone-llvm-2' into beheim/entryPoints
Mar 11, 2021
7c68064
removing duplicate files
Mar 11, 2021
7dec799
proper string handling in return value
Mar 11, 2021
4d1dd88
proper handling of ranges
Mar 11, 2021
992c26a
better test for entry point
Mar 11, 2021
05e6833
correct size for strings
Mar 12, 2021
a32453c
proper int casts for bool and pauli
Mar 12, 2021
0933813
Merge branch 'feature/qir' into beheim/entryPoints
Mar 12, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/QsCompiler/Compiler/RewriteSteps/QirGeneration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public bool PreconditionVerification(QsCompilation compilation)
/// <inheritdoc/>
public bool Transformation(QsCompilation compilation, out QsCompilation transformed)
{
var generator = new Generator(compilation, new Configuration());
var generator = new Generator(compilation);
generator.Apply();
generator.Emit(this.outputFile);
transformed = compilation;
Expand Down
11 changes: 11 additions & 0 deletions src/QsCompiler/Core/SyntaxGenerator.fs
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,17 @@ module SyntaxGenerator =

let QubitArrayType = Qubit |> ResolvedType.New |> ArrayType |> ResolvedType.New

/// Recursively extracts and returns all tuple items in the given tuple.
let ExtractInnerItems (this: ITuple) =
let rec extractAll =
function
| Tuple items -> items |> Seq.collect extractAll
| Item item -> seq { yield item }
| Missing -> ArgumentException "missing item in tuple" |> raise
| _ -> ArgumentException "invalid item in tuple" |> raise

this |> extractAll

/// Given a QsTuple, recursively extracts and returns all of its items.
let ExtractItems (this: QsTuple<_>) = this.Items.ToImmutableArray()

Expand Down
42 changes: 0 additions & 42 deletions src/QsCompiler/QirGeneration/Configuration.cs

This file was deleted.

466 changes: 79 additions & 387 deletions src/QsCompiler/QirGeneration/Context.cs

Large diffs are not rendered by default.

17 changes: 6 additions & 11 deletions src/QsCompiler/QirGeneration/Generator.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

using Microsoft.Quantum.QIR;
using Microsoft.Quantum.QsCompiler.SyntaxTree;
using Microsoft.Quantum.QsCompiler.Transformations.Core;

Expand All @@ -11,11 +12,6 @@ namespace Microsoft.Quantum.QsCompiler.QIR
/// </summary>
public class Generator : SyntaxTreeTransformation<GenerationContext>
{
/// <summary>
/// The configuration used for QIR emission.
/// </summary>
public readonly Configuration Config;

/// <summary>
/// The compilation unit for which QIR is generated.
/// </summary>
Expand All @@ -39,11 +35,9 @@ public class Generator : SyntaxTreeTransformation<GenerationContext>
/// Instantiates a transformation capable of emitting QIR for the given compilation.
/// </summary>
/// <param name="compilation">The compilation for which to generate QIR</param>
/// <param name="config">The configuration for the QIR generation</param>
public Generator(QsCompilation compilation, Configuration config)
: base(new GenerationContext(compilation.Namespaces, config), TransformationOptions.NoRebuild)
public Generator(QsCompilation compilation)
: base(new GenerationContext(compilation.Namespaces), TransformationOptions.NoRebuild)
{
this.Config = config;
this.Compilation = compilation;

this.Namespaces = new QirNamespaceTransformation(this, TransformationOptions.NoRebuild);
Expand All @@ -59,7 +53,7 @@ public Generator(QsCompilation compilation, Configuration config)
}

/// <summary>
/// Constructs the QIR for the compilation.
/// Constructs the QIR for the compilation, including interop-friendly functions for entry points.
/// Does not emit anything; use <see cref="Emit"/> to output the constructed QIR.
/// </summary>
public void Apply()
Expand All @@ -71,7 +65,8 @@ public void Apply()

foreach (var epName in this.Compilation.EntryPoints)
{
this.SharedState.GenerateEntryPoint(epName);
var wrapperName = GenerationContext.EntryPointName(epName);
this.SharedState.CreateInteropWrapper(wrapperName, epName, AttributeNames.EntryPoint);
}
}

Expand Down
Loading