Skip to content

Commit

Permalink
Performance improvements for carrier replica
Browse files Browse the repository at this point in the history
  • Loading branch information
Soeren Schoenbrod committed Mar 26, 2021
1 parent e889fad commit ae3296f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Project.toml
@@ -1,7 +1,7 @@
name = "Tracking"
uuid = "10b2438b-ffd4-5096-aa58-44041d5c8f3b"
authors = ["Soeren Zorn <soeren.zorn@nav.rwth-aachen.de>"]
version = "0.14.2"
version = "0.14.3"

[deps]
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
Expand All @@ -16,7 +16,7 @@ Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"
[compat]
DocStringExtensions = "0.6, 0.7, 0.8"
GNSSSignals = "0.15"
LoopVectorization = "0.8, 0.9, 0.10, 0.11"
LoopVectorization = "0.8, 0.9, 0.10, 0.11, 0.12"
StaticArrays = "0.9, 0.10, 0.11, 0.12, 1.0"
StructArrays = "0.4"
TrackingLoopFilters = "0.1"
Expand Down
6 changes: 5 additions & 1 deletion src/carrier_replica.jl
Expand Up @@ -7,9 +7,13 @@ function gen_carrier_replica!(
num_samples
) where T
c_re = carrier_replica.re; c_im = carrier_replica.im
carr_freq = T(upreferred(carrier_frequency / Hz))
sample_freq = T(upreferred(sampling_frequency / Hz))
twopi = T(2π)
phase = T(start_phase)
@avx for i in 0:num_samples - 1
c_im[i + start_sample], c_re[i + start_sample] =
sincos(T(2π) * (i * T(upreferred(carrier_frequency / Hz)) / T(upreferred(sampling_frequency / Hz)) + T(start_phase)))
sincos(twopi * (i * carr_freq / sample_freq + phase))
end
carrier_replica
end
Expand Down

2 comments on commit ae3296f

@zsoerenm
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/32899

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.14.3 -m "<description of version>" ae3296fa5e2ef524f70e011fbdff48458f851c4d
git push origin v0.14.3

Please sign in to comment.