[lldb-dev] Type lookup by basename vs. qualified name

2018-10-23 Thread Zachary Turner via lldb-dev
I was trying to implemented type lookup for qualified names (e.g. in
namespaces), and I noticed we have this code in Module.cpp:

  if (Type::GetTypeScopeAndBasename(type_name_cstr, type_scope,
type_basename,
type_class)) {
// Check if "name" starts with "::" which means the qualified type
starts
// from the root namespace and implies and exact match. The typenames we
// get back from clang do not start with "::" so we need to strip this
off
// in order to get the qualified names to match
exact_match = type_scope.consume_front("::");

ConstString type_basename_const_str(type_basename);
if (FindTypes_Impl(sc, type_basename_const_str, nullptr, append,
   max_matches, searched_symbol_files, typesmap)) {
  typesmap.RemoveMismatchedTypes(type_scope, type_basename, type_class,
 exact_match);
  num_matches = typesmap.GetSize();
}
  } else {


Basically we are stripping the namespace and scope, and only passing the
basename to the SymbolVendor.  I guess then the SymbolFile will find any
types which match the basename, which could be anything, and the
RemoveMismatchedTypes will filter this down to only the ones that are in
the namespace.

I don't know what this is like in DWARF-land, but for PDB this is
*precisely* what we do not want to do.  Types are indexed in an internal
hash table by fully qualified name, so we need the fully scoped name in the
SymbolFile plugin otherwise we basically have to do the equivalent of a
full table scan for what could be an O(1) operation.

If I change this to pass the fully scoped name, is this going to break
SymbolFileDWARF?
___
lldb-dev mailing list
lldb-dev@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev


Re: [lldb-dev] [llvm-dev] Updates on SVN to GitHub migration

2018-10-23 Thread David Greene via lldb-dev
Apparently the GitHub UI is not great about showing tags.  If you clone
and do git tag you'll see them.  Someone at one of the dev. meeting
roundtables found a way to see them on GitHub but I don't remember the
details.

  -David

Jacob Carlborg via llvm-dev  writes:

> On 2018-10-20 02:47, Tom Stellard via llvm-dev wrote:
>> TLDR: Official monorepo repository will be published on
>> Tuesday, Oct 23, 2018.  After this date, you should modify
>> your workflows to use the monorepo ASAP.  Current workflows
>> will be supported for at most 1 more year.
>
> Looks like the prototype repository [1] is missing quite a lot of
> tags, like all of the RELEASE_NNN tags [2].
>
> [1] https://github.com/llvm-git-prototype/llvm[2] 
> https://llvm.org/svn/llvm-project/cfe/tags/
___
lldb-dev mailing list
lldb-dev@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev


Re: [lldb-dev] [llvm-dev] [Openmp-dev] Updates on SVN to GitHub migration

2018-10-23 Thread David Greene via lldb-dev
Thanks!  In our case we have a branch off master for each component and
we've developed there, merging from master from time to time (but never
our local branch to master).  I guess that puts us in the "multirepo
with merges" category.  We don't really care about maintaining the
history of merges from master.  Even rebasing our changes on the curent
monorepo master would probably be fine (understanding that there will be
merge conflicts we'll need to resolve).

The biggest challenge will be corrdinating changes to subprojects that
depend on each other.  We don't want to just rebase all changes from
subproject X and then all changes from subproject Y, because we'll end
up with unbuildable history for most of the resulting commits.  In the
foggy days of the past, I did our svn-to-git conversion and we had
similar needs, merging multiple svn repositories into one git
repository.  I had to carefully craft scripts to get the commit ordering
right.  I could probably do the same much more easily with git.

I've not used subtree merges in quite the way described so we'll have to
experiment a bit and see what works.

   -David

Justin Lebar  writes:

>> It would be helpful to have instructions about the best way to move
> local branches in those repositories to the monorepo and some scripts
> to help with the transition. 
>
> I put together https://reviews.llvm.org/D53414.
>
> On Mon, Oct 22, 2018 at 8:31 AM David Greene via llvm-dev
>  wrote:
>
> I had a short side-conversation at one of the roundtables about
> existing
> users of the subproject repositories. It would be helpful to have
> instructions about the best way to move local branches in those
> repositories to the monorepo and some scripts to help with the
> transition. I know someone posted an example project a while ago
> with
> some scripts but my sense is that those scripts were particular to
> that
> project and maybe not generally applicable.
> 
> Once the monorepo goes live (tomorrow?), what happens to the
> existing
> subproject mirrors? Do they get wiped away and replaced with
> history
> from the monorepo? Or are entirely new mirrors created? Or do they
> just continue to mirror SVN until SVN becomes read-only?
> 
> The first option would essentially be a rewrite of history for the
> subproject repositories. We'll need to know if/when that is going
> to
> happen.
> 
> -David
> 
> Jonas Hahnfeld via Openmp-dev  writes:
> 
> > (+openmp-dev, they should know about this!)
> >
> > Recapping the "Concerns"
> > (https://llvm.org/docs/Proposals/GitHubMove.html#id12) there is
> a
> > proposal of "single-subproject Git mirrors" for people who are
> only
> > contributing to standalone subprojects. I think this will be
> easy in
> > the transition period, we can just continue to move the current
> > official git mirrors. Will this "service" be continued after
> GitHub
> > becomes the 'one source of truth'? I'd strongly vote for yes,
> but I'm
> > not sure how that's going to work on a technical level.
> >
> > Thanks,
> > Jonas
> >
> > On 2018-10-20 03:14, Tom Stellard via llvm-dev wrote:
> >> On 10/19/2018 05:47 PM, Tom Stellard via lldb-dev wrote:
> >>> TLDR: Official monorepo repository will be published on
> >>> Tuesday, Oct 23, 2018. After this date, you should modify
> >>> your workflows to use the monorepo ASAP. Current workflows
> >>> will be supported for at most 1 more year.
> >>>
> >>> Hi,
> >>>
> >>> We had 2 round-tables this week at the Developer Meeting to
> >>> discuss the SVN to GitHub migration, and I wanted to update
> >>> the rest of the community on what we discussed.
> >>>
> >>> The most important outcome from that meeting is that we
> >>> now have a timeline for completing the transition which looks
> >>> like this:
> >>>
> >>
> >> Step 1:
> >>> Tues Oct 23, 2018:
> >>>
> >>> The latest monorepo prototype[1] will be moved over to the
> LLVM
> >>> organization github project[2] and will begin mirroring the
> current
> >>> SVN repository. Commits will still be made to the SVN
> repository
> >>> just as they are today.
> >>>
> >>> All community members should begin migrating their workflows
> that
> >>> rely on SVN or the current git mirrors to use the new
> monorepo.
> >>>
> >>> For CI jobs or internal mirrors pulling from SVN or
> >>> http://llvm.org/git/*.git you should modify them to pull from
> >>> the new monorepo and also to deal with the new repository
> >>> layout.
> >>>
> >>> For Developers, you should begin using the new monorepo
> >>> for your development and using the provided scripts[3]
> >>> to commit your code. These scripts will allow to commit
>   

[lldb-dev] [Bug 39405] New: JSON parser in LLDB does not accept []

2018-10-23 Thread via lldb-dev
https://bugs.llvm.org/show_bug.cgi?id=39405

Bug ID: 39405
   Summary: JSON parser in LLDB does not accept []
   Product: lldb
   Version: unspecified
  Hardware: Other
OS: All
Status: NEW
  Severity: enhancement
  Priority: P
 Component: All Bugs
  Assignee: lldb-dev@lists.llvm.org
  Reporter: david.bolvan...@gmail.com
CC: llvm-b...@lists.llvm.org

Internal JSON parser in LLDB does not accept valid “[]”.
Maybe is it worth to do some refactoring and use JSON lib from LLVM in LLDB?

-- 
You are receiving this mail because:
You are the assignee for the bug.___
lldb-dev mailing list
lldb-dev@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev